Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
Yeah i have this 5000 rows of data to populate. Lets copy paste the print code that many times, because we can.
-
C0D4669446yI ain't copy/pasting the same code block 1.5 million times. You sir "Mr loopless" can go do that for me and maintain it too.
-
I once worked with a guy that I asked to do some very basic load testing just to get a rough idea of what his code could handle.
He wrote a piece of node.js to send a request once per second. He then copy pasted it 450 times into a file as his load test.
I asked him how did he plan on increasing or decreasing the number of requests. And he said he’d either delete a few of them or copy paste more in.
I was speechless -
@practiseSafeHex ouch, like actual physical pain in my chest from reading that...
I think I would sit down for a couple of minutes to take that in... -
Root797346y@practiseSafeHex I would have asked him to change the requests a few times.
♡ "Hey, could you reduce the time between requests to half a second?"
♡ "Hey, could you change the data you're sending?"
♡ "Hey, send a thousand in ten seconds; let's try that."
♡ "Let's let this run all night for a durability test. Have it run for 10 hours and we'll check on it in the morning. 10 requests a second should do nicely."
If he didn't get it by then... -
Pickman6526yThe question is fair if posed by someone taking Programming 101.
However the real question is: "How are loops more expressive than normal code?"
And if you think that it's because they're more convenient I'm sorry but you're wrong. A language without loops is not Turing-complete, there are problems that require loops to be solved.
Related Rants
I don't even know what to say.
rant
generation npm
loops
wut da frigg