Skip to content

Birmingham | 26-ITP-May | Tobias Amaechina | Sprint 1 | Group data sprint 1 - #1283

Open
Tobias-Amaechina wants to merge 38 commits into
CodeYourFuture:mainfrom
Tobias-Amaechina:group-data-sprint-1
Open

Birmingham | 26-ITP-May | Tobias Amaechina | Sprint 1 | Group data sprint 1#1283
Tobias-Amaechina wants to merge 38 commits into
CodeYourFuture:mainfrom
Tobias-Amaechina:group-data-sprint-1

Conversation

@Tobias-Amaechina

Copy link
Copy Markdown

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

Sprint-1/fix/median.js
I Validated input and handle non-array input.
Convert numeric strings to numbers and ignore non-numeric values.
Sort numeric values and return correct median for odd/even lengths.
Return null when there are no numeric values.
Sprint-1/implement/dedupe.js
I Implemented dedupe using Set to remove duplicates and return unique elements.
Sprint-1/implement/dedupe.test.js
Replaced todo with unit tests for empty arrays, arrays without duplicates, and arrays with duplicates (strings and numbers).
Sprint-1/implement/max.js
Implemented findMax: filter numeric values then return Math.max(...) (ignores non-numeric values).
Sprint-1/implement/max.test.js
Replaced todo with multiple unit tests covering empty arrays, single value, negatives, decimals, mixed types, and only-non-number cases.
Sprint-1/implement/sum.js
Implemented sum: filter numeric values, reduce, and normalize floating point with toFixed(10).
Sprint-1/implement/sum.test.js
Replaced todo with tests for empty, single, negative, decimal, mixed and only-non-number arrays.
Sprint-1/refactor/includes.js
Minor refactor: renamed parameter to array and used index-based loop; behavior preserved.
Sprint-1/package-lock.json
Updated many dev dependency versions (package-lock updated — likely from npm install / dependency updates).
Brief explanation

…er were passed that it reurns the largest numer overall
…oring non-numeric value when given an array of both numeric and non-numeric values
…at it returns the least surprising value which is -Infinity
…oth positive and negative are passed to the sum function
…ignore the non-numerical values when give array of both numeric and non-numeric values
…merical value and numerical values as pass as array into the fn
@Tobias-Amaechina Tobias-Amaechina added the Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. label Jul 23, 2026

@hey-hammad hey-hammad left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

@Tobias-Amaechina please fix the failing test cases. Thanks

@hey-hammad hey-hammad added Review in progress This review is currently being reviewed. This label will be replaced by "Reviewed" soon. 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. Review in progress This review is currently being reviewed. This label will be replaced by "Reviewed" soon. labels Jul 28, 2026
@Tobias-Amaechina

Copy link
Copy Markdown
Author

Thanks for the feed back , all test has now passed

@Tobias-Amaechina Tobias-Amaechina added the Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. label Jul 29, 2026
@hey-hammad hey-hammad removed the Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. label Jul 29, 2026

@hey-hammad hey-hammad left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Good clean code overall, once minor change required.

@@ -1,12 +1,12 @@
// Refactor the implementation of includes to use a for...of loop

@hey-hammad hey-hammad Jul 29, 2026

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

please read the instruction for this exercise again.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Thank you for the feedback, the function has been refactored to include for .. of loop .

@Tobias-Amaechina Tobias-Amaechina added the Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. label Jul 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

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.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants