Skip to content

Atiqa N.#18

Open
atiqanaseer wants to merge 1 commit intoHackYourAssignment:mainfrom
atiqanaseer:main
Open

Atiqa N.#18
atiqanaseer wants to merge 1 commit intoHackYourAssignment:mainfrom
atiqanaseer:main

Conversation

@atiqanaseer
Copy link

No description provided.

@github-actions
Copy link

📝 HackYourFuture auto grade

Assignment Score: 0 / 100 ✅

Status: ✅ Passed
Minimum score to pass: 0
🧪 The auto grade is experimental and still being improved

Test Details

@sycons sycons self-assigned this Feb 21, 2026
Copy link

@sycons sycons left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good job! ⭐
You did the assignment well and showed understanding of the concepts.

Setup & Configuration ✅
Data Structure ✅
Required Functions ✅
Error Handling ✅
Display (Chalk) ✅

// Handle missing file (create empty array)
// Handle invalid JSON (notify user, use empty array)
// Use try-catch for error handling
// TODO: Implement this function
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's good practice to remove TODO comments after you've implemented them. Keeps the code cleaner and shows more clearly the requirement has been implemented.

// TODO: Implement this function using filter()
const books = loadBooks();
return books.filter(
(book) => book.genre.toLowerCase() === genre.toLowerCase()
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice touch converting to lower case when comparing strings ⭐
Also a real world scenario that happens often in apps.

const books = loadBooks();
const updatedBooks = books.map((book) => {
if (book.id === id) book.read = true;
return book;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pay attention to indenting.

@sycons sycons added Reviewed This assignment has been reivewed by a mentor and a feedback has been provided and removed To review labels Feb 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Reviewed This assignment has been reivewed by a mentor and a feedback has been provided

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants