Quick JS solution
const dgmf = (init, lim) => { let count = 0 for (var i = init-1;i < lim+1;i++) { count = String(i).includes('5') ? count : count + 1 // count = i % 5 != 0 ? count + 1 : count } return count }
This removes more than 5s
True, just realized 😂
Changing the conditional expression should fix that
// ... // Loop code count = String(i).includes('5') ? count : count + 1
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Quick JS solution
This removes more than 5s
True, just realized 😂
Changing the conditional expression should fix that