Skip to content

Conversation

@khalidbih
Copy link

@khalidbih khalidbih commented Nov 7, 2025

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

I completed all exercises in Sprint-2, except the last one, 5-stretch-extend/format-time.js.

@github-actions
Copy link

github-actions bot commented Nov 7, 2025

Your PR description contained template fields which weren't filled in.

Check you've ticked everything in the self checklist, and that any sections which prompt you to fill in an answer are either filled in or removed.

If this PR is not coursework, please add the NotCoursework label (and message on Slack in #cyf-curriculum or it will probably not be noticed).

@khalidbih khalidbih added 📅 Sprint 2 Assigned during Sprint 2 of this module Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. Module-Structuring-And-Testing-Data The name of the module. labels Nov 7, 2025
@github-actions
Copy link

github-actions bot commented Nov 7, 2025

Your PR description contained template fields which weren't filled in.

Check you've ticked everything in the self checklist, and that any sections which prompt you to fill in an answer are either filled in or removed.

If this PR is not coursework, please add the NotCoursework label (and message on Slack in #cyf-curriculum or it will probably not be noticed).

2 similar comments
@github-actions
Copy link

github-actions bot commented Nov 7, 2025

Your PR description contained template fields which weren't filled in.

Check you've ticked everything in the self checklist, and that any sections which prompt you to fill in an answer are either filled in or removed.

If this PR is not coursework, please add the NotCoursework label (and message on Slack in #cyf-curriculum or it will probably not be noticed).

@github-actions
Copy link

github-actions bot commented Nov 7, 2025

Your PR description contained template fields which weren't filled in.

Check you've ticked everything in the self checklist, and that any sections which prompt you to fill in an answer are either filled in or removed.

If this PR is not coursework, please add the NotCoursework label (and message on Slack in #cyf-curriculum or it will probably not be noticed).

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.

  • This branch contains some unrelated changes in the Sprint-1 folder. Can you revert those changes to keep this branch clean?

Comment on lines 18 to 19
let BMI = weight / (height * height);
let rounded = Math.round(BMI * 10) / 10;
Copy link
Contributor

Choose a reason for hiding this comment

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

Did you notice the variables rounded and BMI are rendered in different colors?

Many IDEs and viewers that support syntax highlighting (including GitHub) display identifiers in different formats and colors.

let bmi, camelCase;
let Bmi, PascalCase;
let BMI, UPPER_SNAKE_CASE;

Can you look up the naming conventions in JavaScript? In particular,

  • Variable and function names
  • Class and Types names
  • Named constants

Then, update the variable names according to those conventions.


On separate note, it is a good practice to declare a "variable" using const instead of let when the variable is not going to be reassigned a value.

Copy link
Author

Choose a reason for hiding this comment

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

Thank you! I have changed let to const and checked the variable naming.

Comment on lines +7 to +25
function toPounds (penceString) {


const penceStringWithoutTrailingP = penceString.substring (
0,
penceString.length - 1
);

const paddedPenceNumberString = penceStringWithoutTrailingP.padStart(3, "0");
const pounds = paddedPenceNumberString.substring(
0,
paddedPenceNumberString.length - 2
);

const pence = paddedPenceNumberString
.substring(paddedPenceNumberString.length - 2)
.padEnd(2, "0");
return ${pounds}.${pence}`;
}
Copy link
Contributor

Choose a reason for hiding this comment

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

The indentation of the code is a bit off.

Suggestion: You can use this VSCode feature to auto indent JS code.
https://code.visualstudio.com/docs/languages/javascript#_formatting

Copy link
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 link! I’ll make sure to keep the indentation consistent next time.

@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
Deleted unrelated Sprint-1 files that were mistakenly included in the Sprint-2 branch to keep the PR clean.
Deleted unrelated Sprint-1 files that were mistakenly included in the Sprint-2 branch to keep the PR clean.
Deleted unrelated Sprint-1 files that were mistakenly included in the Sprint-2 branch to keep the PR clean.
Deleted unrelated Sprint-1 files that were mistakenly included in the Sprint-2 branch to keep the PR clean.
@khalidbih
Copy link
Author

  • This branch contains some unrelated changes in the Sprint-1 folder. Can you revert those changes to keep this branch clean?

Sorry about the confusion! I’ve deleted the unrelated changes to keep this branch clean.

@khalidbih khalidbih added Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. and removed Reviewed Volunteer to add when completing a review with trainee action still to take. labels Nov 11, 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 to the code look good. However, the branch is still not quite clean.

Deleted files are still considered as "changed files". "Revert the changes made in the Sprint-1 folder" means to "undo the changes made in that folder. That is, we need to make the files in the Sprint-1 folder identical to their original version (the version in the main branch).
One way to achieve that is to replace the files by the version of the files in main.

@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 12, 2025
@khalidbih
Copy link
Author

Changes to the code look good. However, the branch is still not quite clean.

Deleted files are still considered as "changed files". "Revert the changes made in the Sprint-1 folder" means to "undo the changes made in that folder. That is, we need to make the files in the Sprint-1 folder identical to their original version (the version in the main branch). One way to achieve that is to replace the files by the version of the files in main.

.Sprint-1 files have been restored to main and removed from this PR to keep the changes focused and clean.

@khalidbih khalidbih added Needs Review Trainee to add when requesting review. PRs without this label will not be reviewed. and removed Reviewed Volunteer to add when completing a review with trainee action still to take. labels Nov 12, 2025
@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. labels Nov 12, 2025
@cjyuan
Copy link
Contributor

cjyuan commented Nov 12, 2025

Branch is clean now. Well done.

@khalidbih
Copy link
Author

Branch is clean now. Well done.

Thank you so much for your guidance. I really appreciate it.

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. Module-Structuring-And-Testing-Data The name of the module. 📅 Sprint 2 Assigned during Sprint 2 of this module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants