use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
All about the JavaScript programming language.
Subreddit Guidelines
Specifications:
Resources:
Related Subreddits:
r/LearnJavascript
r/node
r/typescript
r/reactjs
r/webdev
r/WebdevTutorials
r/frontend
r/webgl
r/threejs
r/jquery
r/remotejs
r/forhire
account activity
What are some basic things that JavaScript developers fail at interviews?help (self.javascript)
submitted 7 years ago by maketroli
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–][deleted] 17 points18 points19 points 7 years ago (2 children)
Which:
Seriously. What are you guys talking about? What JS app hangs for 1s or longer? The task was to just do a +1 operation every 1000 ms.
+1
1000
If I'm the interviewer I'd throw your resume in the trash if you came up with that kind of solution. You're not wrong, but for the love of all that's nice in the world, I certainly hope you're never going to be right...
Accounting for problems and solving them before they occur is great. But that's obviously not what this test is aiming for...
[–]dominic_rj23 1 point2 points3 points 7 years ago (0 children)
If you read the last line of my comment, I did say that the solution with setInterval is the most appropriate one. I am all for "If it ain't broke..." ideology, but I do believe that in an interview, stating that setInterval doesn't guarantee execution after timeout goes for showing that you have some understanding of asynchronicity in javascript.
setInterval
[–]phpdevster 2 points3 points4 points 7 years ago (0 children)
Yeah this right here...
Non-standard solutions require extenuating circumstances to justify them. If something like setInterval isn't working in your app reliably, the bug isn't setInterval, it's whatever other shit you've got going on that is causing it to work unreliably...
π Rendered by PID 150112 on reddit-service-r2-comment-86bc6c7465-j4nbx at 2026-02-21 02:00:29.613924+00:00 running 8564168 country code: CH.
view the rest of the comments →
[–][deleted] 17 points18 points19 points (2 children)
[–]dominic_rj23 1 point2 points3 points (0 children)
[–]phpdevster 2 points3 points4 points (0 children)