DEV Community

Discussion on: a classic watch , width HTML CSS JS

Collapse
 
tracygjg profile image
Tracy Gilmore

Nice job Mohammad. In the JavaScript for loop, if you replace the less-than (<) for a less-than or equal to (<=) you can drop the + 1.
Instead of

for (let i = 1; i < c_numbers_count + 1; i++)
Enter fullscreen mode Exit fullscreen mode

use

for (let i = 1; i <= c_numbers_count; i++)
Enter fullscreen mode Exit fullscreen mode
Collapse
 
kiumad profile image
Mohammad Mirfatemi

Thanks a lot @tracygjg .
It was an interesting and informative point for me

Collapse
 
tracygjg profile image
Tracy Gilmore

Thanks for accepting the PR but don't forget to update CodePen.

Thread Thread
 
kiumad profile image
Mohammad Mirfatemi

Yes, Sure
Thank you again