Skip to content

Conversation

@enjoy15
Copy link

@enjoy15 enjoy15 commented Oct 26, 2025

Learners, PR Template

Self checklist

  • I have titled my PR with Region | Cohort | FirstName LastName | Sprint | Assignment Title
  • My changes meet the requirements of the task
  • I have tested my changes
  • My changes follow the style guide

Changelist

-Completed all excercises in Sprint-1

@enjoy15 enjoy15 added 📅 Sprint 1 Assigned during Sprint 1 of this module Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. labels Oct 26, 2025
Copy link
Contributor

@cjyuan cjyuan left a comment

Choose a reason for hiding this comment

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

You missed updating Sprint-1/implement/sum.js and Sprint-1/implement/sum.test.js.

@cjyuan cjyuan added Reviewed Volunteer to add when completing a review with trainee action still to take. and removed Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. labels Nov 8, 2025
@enjoy15
Copy link
Author

enjoy15 commented Nov 20, 2025

You missed updating Sprint-1/implement/sum.js and Sprint-1/implement/sum.test.js.

Sprint-1/implement/sum.js and Sprint-1/implement/sum.test.js are updated.

@enjoy15 enjoy15 added the Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. label Nov 20, 2025
Copy link
Contributor

@cjyuan cjyuan left a comment

Choose a reason for hiding this comment

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

Changes look good.

}

// Sort the numbers in ascending order (don't mutate original array)
const sorted = [...numbers].sort((a, b) => a - b);
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it necessary to clone numbers?

Comment on lines +34 to +35
expect(result).toEqual(original); // same values
expect(result).not.toBe(original); // different reference
Copy link
Contributor

Choose a reason for hiding this comment

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

Good job.

Comment on lines +61 to +63
expect(findMax(["hey", 10, "hi", 60, 10])).toBe(60);
expect(findMax([5, "hello", 15, null, 10, undefined])).toBe(15);
expect(findMax([1, "test", 2, NaN, 3])).toBe(3);
Copy link
Contributor

Choose a reason for hiding this comment

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

Could also include strings that can usually be safely converted to numbers (e.g., "100", "3e2") to ensure the function can properly ignore values that are not numbers.

@cjyuan cjyuan added Complete Volunteer to add when work is complete and all review comments have been addressed. and removed Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. Reviewed Volunteer to add when completing a review with trainee action still to take. labels Nov 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Complete Volunteer to add when work is complete and all review comments have been addressed. 📅 Sprint 1 Assigned during Sprint 1 of this module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants