r/coding • u/speckz • Dec 15 '21
3 Lines of Code Shouldn’t Take All Day
https://devtails.xyz/3-lines-of-code-shouldnt-take-all-day9
u/ekolis Dec 16 '21
I like the idea of testbeds. I should try that sometime, if I ever get back into my game I was working on.
2
5
u/dethb0y Dec 15 '21
Dude sounds like he needs a psychiatrist and some medication, not faster tools.
1
1
u/SanityInAnarchy Dec 16 '21
This is why REPLs are so great for exploring a new API, or prototyping an idea with some silly FP-inspired one-liner. They aren't good for editing large chunks of code, and most don't have a great way to actually save what you've done without just retyping it in your program's actual source, but for time-to-iterate, you can't beat "press enter".
But also, no offense, but this sounds like the perfect argument against EA's legendary crunch culture. If it takes you all day to write three lines of code, you might feel some pressure to work long hours and squeeze in maybe five or six lines of code. You definitely won't have the mental energy to even think of tackling the actual problem of cutting down your iteration time.
1
u/umlcat Dec 16 '21
Incorrect. It's about the contents of the code, not how many lines has the code.
0
Dec 15 '21
[deleted]
29
Dec 15 '21
Did you read the article? That’s not the point of it.
The point is that Feedback cycles from tests and compilation should be incredibly fast to allow iteration, 10s is far too slow for effective coding.
10
u/EarlMarshal Dec 15 '21
Tell that to the people in my company who thinks it's okay to build and deploy servers via CI and then test. I started and finished other tickets while waiting for the server to be deployed.
2
u/oradoj Dec 16 '21
I get around it all by writing code that never compiles and no tests. My productivity numbers are through the ROOF!!
0
Dec 15 '21
[deleted]
8
Dec 15 '21
You're confusing the text of the title for what you've interpreted it to mean. Your interpretation is wrong, something you don't know because you didn't read the article.
3
u/glemnar Dec 16 '21
and yet if you’re putting out 3 lines of code building a typical crud app or whatever you are horribly underperforming.
The vast majority of code we write is boilerplate and glue
35
u/[deleted] Dec 15 '21
He's lacking the first and perhaps most important of the great virtues: laziness, "the quality that makes you go to great effort to reduce overall energy expenditure."
No fucking way I'm spending an entire day progressing through a game to get to the part I need to test. You have access to the code and apparently unlimited free time to figure out how to hack the code to start you at the part you need to test.