subreddit
stringclasses
7 values
author
stringlengths
3
20
id
stringlengths
5
7
content
stringlengths
67
30.4k
score
int64
0
140k
programminghorror
seyfahni
h36utyy
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>That's still good! When I was correcting the biweekly tasks for the programming basics lession at my university I came across one who used only if to represent every possible path the game could take....
206
programminghorror
samu698
h36ymtm
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>I guess this is checking if someone won in tic tac toe and I tried to code this too, I couldn't come up with any better solution. does someone have suggestions?<|eor|><|eols|><|endoftext|>
134
programminghorror
wind-raven
h37ubih
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>There are simple ways, complex ways, and ways that work well enough to push it to production and move on to the next problem. This would fall into the third and is something I would probably write as...
66
programminghorror
samu698
h37bc25
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>I guess this is checking if someone won in tic tac toe and I tried to code this too, I couldn't come up with any better solution. does someone have suggestions?<|eor|><|sor|>I found [this](https://...
64
programminghorror
martinslot
h36z7r6
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>I guess this is checking if someone won in tic tac toe and I tried to code this too, I couldn't come up with any better solution. does someone have suggestions?<|eor|><|sor|>Can't it be solved someh...
29
programminghorror
sixstringartist
h3821p4
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>There are simple ways, complex ways, and ways that work well enough to push it to production and move on to the next problem. This would fall into the third and is something I would probably write as...
27
programminghorror
mortelsson
h39811u
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>The fact that everyone in this thread immediately figured out it's TicTacToe makes it an excellent solution. You don't always have to come up with general solutions to every problem. TicTacToe has 8...
24
programminghorror
Fahrenheight
h37bl6p
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>I guess this is checking if someone won in tic tac toe and I tried to code this too, I couldn't come up with any better solution. does someone have suggestions?<|eor|><|sor|>Magic square. Every line...
22
programminghorror
Sir_NaCl
h3716xw
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>At least they where smart enough to not use a redundant else statement<|eor|><|sor|>Well, they could also just return the logic operation but sure<|eor|><|eols|><|endoftext|>
22
programminghorror
intensely_human
h3a0j4l
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>That's still good! When I was correcting the biweekly tasks for the programming basics lession at my university I came across one who used only if to represent every possible path the game could take....
20
programminghorror
Bob-The-One
h37rio8
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>I guess this is checking if someone won in tic tac toe and I tried to code this too, I couldn't come up with any better solution. does someone have suggestions?<|eor|><|sor|>I found [this](https://...
20
programminghorror
foxfyre2
h37rt21
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>I guess this is checking if someone won in tic tac toe and I tried to code this too, I couldn't come up with any better solution. does someone have suggestions?<|eor|><|sor|>Can't it be solved someh...
18
programminghorror
Berjiz
h37aur7
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>I guess this is checking if someone won in tic tac toe and I tried to code this too, I couldn't come up with any better solution. does someone have suggestions?<|eor|><|sor|>Can't it be solved someh...
17
programminghorror
furon747
h37yoz1
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>Tic Tac Toe? I mean, still better than my code (Javascript) &#x200B; function winCheck(){ // Horizontal check for(i=0;i<3;i++){ if(board[i][0]==board[i][1]&&board[i][1]==board...
16
programminghorror
NikkoTheGreeko
h37odby
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>I guess this is checking if someone won in tic tac toe and I tried to code this too, I couldn't come up with any better solution. does someone have suggestions?<|eor|><|sor|>There are 43,722 npm pac...
15
programminghorror
sam-lb
h37lxey
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>I guess this is checking if someone won in tic tac toe and I tried to code this too, I couldn't come up with any better solution. does someone have suggestions?<|eor|><|sor|>It's actually easier if ...
15
programminghorror
iWelcomeTheDownVote
h37rhnp
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>I guess this is checking if someone won in tic tac toe and I tried to code this too, I couldn't come up with any better solution. does someone have suggestions?<|eor|><|sor|>It's actually easier if ...
15
programminghorror
staletic
h379juc
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>I guess this is checking if someone won in tic tac toe and I tried to code this too, I couldn't come up with any better solution. does someone have suggestions?<|eor|><|sor|> for(int i = 0; i < 3...
12
programminghorror
PotentBeverage
h39d1tp
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>I guess this is checking if someone won in tic tac toe and I tried to code this too, I couldn't come up with any better solution. does someone have suggestions?<|eor|><|sor|>I found [this](https://...
11
programminghorror
Regist33l3
h38arjy
<|sols|><|sot|>Why use lists when an if statement will do<|eot|><|sol|>https://i.redd.it/e2tpywiv0r771.jpg<|eol|><|sor|>There are simple ways, complex ways, and ways that work well enough to push it to production and move on to the next problem. This would fall into the third and is something I would probably write as...
10
programminghorror
yungwhiteclaudia
126k8tp
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|eoss|><|endoftext|>
833
programminghorror
dchidelf
je9nkj1
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>I dont have any data, but what I do have is a particular set of fields<|eor|><|eoss|><|en...
916
programminghorror
codebygloom
je9yuus
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>People just don't appreciate ASCII art anymore.<|eor|><|eoss|><|endoftext|>
295
programminghorror
timoto
je9rkdi
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>Technically valid JSON, the best kind of JSON<|eor|><|eoss|><|endoftext|>
242
programminghorror
Totally_Temporary
jea0q4m
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>i like the ""price": null" at the bottom just a cherry on top<|eor|><|eoss|><|endoftext|...
201
programminghorror
violet_zamboni
jeaet53
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>I dont have any data, but what I do have is a particular set of fields<|eor|><|sor|>Havin...
125
programminghorror
BeastlyIguana
je9zi8p
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>we have nosql at home nosql at home:<|eor|><|eoss|><|endoftext|>
93
programminghorror
egmono
jea48en
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>When you use the api "WonderWoman," but all that comes up is a list of parts to her jet.....
57
programminghorror
LFK1236
jebs1fw
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>i like the ""price": null" at the bottom just a cherry on top<|eor|><|sor|>It's priceles...
48
programminghorror
Nlelith
jeahwga
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>Maybe it's an integer, just as a [set-theoretic formulation of the naturals](https://en.m...
46
programminghorror
chupmacabre
jecasx9
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>Technically valid JSON, the best kind of JSON<|eor|><|sor|> { Your: { mom: [ ...
44
programminghorror
gjwklgwiovmw
je9vtvt
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>why use jsfuck when you have jsonfuck<|eor|><|eoss|><|endoftext|>
42
programminghorror
IJustAteABaguette
jeb5bej
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>I dont have any data, but what I do have is a particular set of fields<|eor|><|sor|>The f...
39
programminghorror
Vegetable-Two6892
je9kcyc
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>maybe its morse code?<|eor|><|eoss|><|endoftext|>
37
programminghorror
Mrraar
je9omrm
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>maybe its morse code?<|eor|><|sor|>I think it translates to: "kill me"<|eor|><|eoss|><|en...
37
programminghorror
adenzerda
jeav7n8
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>It might make sense to do this when there's no data if you've got a strongly-typed appli...
34
programminghorror
q1a2z3x4s5w6
jeardq8
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>Which api was this?<|eor|><|sor|>{ [ { } ] }<|eor|>...
25
programminghorror
ZylonBane
je9prvw
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>Java? Or php?<|eor|><|sor|>Country? Or western?<|eor|><|eoss|><|endoftext|>
18
programminghorror
zachpuls
jebcbu0
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>i like the ""price": null" at the bottom just a cherry on top<|eor|><|sor|>The item didn...
17
programminghorror
RichCorinthian
je9uo0f
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>Java? Or php?<|eor|><|sor|>I'm pretty sure you can trick any back-end stack into producin...
16
programminghorror
EagleCoder
jebh0qv
<|soss|><|sot|>Actual response I get from an actual production API<|eot|><|sost|>&#x200B; https://preview.redd.it/w5hfxu314vqa1.png?width=702&format=png&auto=webp&v=enabled&s=ded12ee58dafe26ae5397ccbfd4fb0f4ae6b155a<|eost|><|sor|>I dont have any data, but what I do have is a particular set of fields<|eor|><|sor|>"a pa...
13
programminghorror
DaRealNim
pfpjwe
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|eols|><|endoftext|>
829
programminghorror
ings0c
hb6hv49
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>Oh lord thats horrific Given the name, I thought it was reversing the digits at first which might not have been so awful (eg 123 becomes -321). but its not <|eor|><|eols|><|endoftext|>
198
programminghorror
Zeftax
hb69clj
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>I have seen someone round a number using similiar approach :D<|eor|><|eols|><|endoftext|>
77
programminghorror
bitesizedmustard1
hb6rc0s
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>not the best way, but if it works it works IG<|eor|><|soopr|>Or just, you know Return -num ...<|eoopr|><|sor|>Why return -num when you can develop an innovative approach to mathematics by using strings of which no pr...
64
programminghorror
DaRealNim
hb6p5z0
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>not the best way, but if it works it works IG<|eor|><|soopr|>Or just, you know Return -num ...<|eoopr|><|eols|><|endoftext|>
51
programminghorror
L4sgc
hb6pwkw
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>Clearly the number is not married, so multiplication would be a sin.<|eor|><|eols|><|endoftext|>
44
programminghorror
O_X_E_Y
hb6sejq
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>Oh lord thats horrific Given the name, I thought it was reversing the digits at first which might not have been so awful (eg 123 becomes -321). but its not <|eor|><|sor|>Yeah I thought string.reverse() or something...
40
programminghorror
xigoi
hb6tllk
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>I have seen someone round a number using similiar approach :D<|eor|><|sor|>https://i.imgur.com/OGOzTG0.jpg<|eor|><|eols|><|endoftext|>
32
programminghorror
bitesizedmustard1
hb6ru41
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>not the best way, but if it works it works IG<|eor|><|soopr|>Or just, you know Return -num ...<|eoopr|><|sor|>Why return -num when you can develop an innovative approach to mathematics by using strings of which no pr...
28
programminghorror
shupack
hb7myn9
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>Oh lord thats horrific Given the name, I thought it was reversing the digits at first which might not have been so awful (eg 123 becomes -321). but its not <|eor|><|sor|>(I'm still learning) this is so strange i ca...
27
programminghorror
Objective-Answer
hb7gcha
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>ah, the issue is you're not using neither lodash or jQuery... c'mon! this is JavaScript day 1 stuff!<|eor|><|eols|><|endoftext|>
26
programminghorror
DaRealNim
hb6ppag
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>I have seen someone round a number using similiar approach :D<|eor|><|soopr|><|eoopr|><|eols|><|endoftext|>
25
programminghorror
ings0c
hb7n19t
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>Oh lord thats horrific Given the name, I thought it was reversing the digits at first which might not have been so awful (eg 123 becomes -321). but its not <|eor|><|sor|>(I'm still learning) this is so strange i ca...
25
programminghorror
atomitac
hb72g6f
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>This is an interesting thing: I studied for a master of science in computer science. Here in Sweden that means that out of those 5 years in higher education you do about 1.5 years of pure math (and another half a yea...
24
programminghorror
Spyes23
hb7rzjb
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>My god, this is like taking a bus two cities over and then paying for a taxi back just to get to your nextdoor neighbor's house.<|eor|><|eols|><|endoftext|>
20
programminghorror
ZylonBane
hb83hb3
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>Oh lord thats horrific Given the name, I thought it was reversing the digits at first which might not have been so awful (eg 123 becomes -321). but its not <|eor|><|sor|>(I'm still learning) this is so strange i ca...
17
programminghorror
Eccentricc
hb6im8k
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>not the best way, but if it works it works IG<|eor|><|eols|><|endoftext|>
15
programminghorror
DaRealNim
hb6pjv5
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>not the best way, but if it works it works IG<|eor|><|sor|>..for integers.<|eor|><|sor|>for what does it not work? only case I could imagine would be a number like 4.5\^-12<|eor|><|soopr|>It uses parseInt. So if you ...
15
programminghorror
TimeToBecomeEgg
hb6uxd3
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>[deleted]<|eor|><|sor|>return num \* -1<|eor|><|eols|><|endoftext|>
13
programminghorror
spader1
hb8wywk
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>Oh lord thats horrific Given the name, I thought it was reversing the digits at first which might not have been so awful (eg 123 becomes -321). but its not <|eor|><|sor|>(I'm still learning) this is so strange i ca...
11
programminghorror
DaRealNim
hb6rocn
<|sols|><|sot|>*pukes in mouth a little*<|eot|><|sol|>https://i.redd.it/v4o04ssbwrk71.png<|eol|><|sor|>not the best way, but if it works it works IG<|eor|><|soopr|>Or just, you know Return -num ...<|eoopr|><|sor|>Why return -num when you can develop an innovative approach to mathematics by using strings of which no pr...
10
programminghorror
Cerlancism
dy46dz
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|eols|><|endoftext|>
826
programminghorror
stevethedev
f7yll0h
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>A perfect example of why "lines of code" is a poor metric for progress or productivity.<|eor|><|eols|><|endoftext|>
282
programminghorror
Bobbar84
f7yux39
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>A perfect example of why "lines of code" is a poor metric for progress or productivity.<|eor|><|sor|>Well it's a good metric for "work"...<|eor|><|eols|><|endoftext|>
88
programminghorror
RedGeoBlaze
f7yfrd6
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>Why stop there? if (input == "10 * 26") printf(" = 260");<|eor|><|eols|><|endoftext|>
71
programminghorror
SexyMonad
f7ym4gd
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>*"Lets' see the compiler optimise this shit!"*<|eor|><|eols|><|endoftext|>
53
programminghorror
MiataCory
f7ylmrn
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>Clearly he was paid [by the line](https://imgur.com/kDLFsvp).<|eor|><|eols|><|endoftext|>
39
programminghorror
TheBackOfTheMeme
f7zl069
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>A perfect example of why "lines of code" is a poor metric for progress or productivity.<|eor|><|sor|>Well it's a good metric for "work"...<|eor|><|sor|>The more bugs you make ...
36
programminghorror
RuthBaderBelieveIt
f7zvcxz
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>[deleted]<|eor|><|sor|>O(n) is O(n) even if n is large<|eor|><|eols|><|endoftext|>
28
programminghorror
FallenWarrior2k
f7yuqu3
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>Why stop there? if (input == "10 * 26") printf(" = 260");<|eor|><|sor|>Except you've made a condition that will always be false because string literals are generally stored i...
28
programminghorror
chocoPhobic
f7ytai2
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>This looks like the persons first project. Really wanna see how he will react in a couple of month after he had made some practice, and learned he could do it easier.<|eor|><|...
28
programminghorror
Cerlancism
f7y7yku
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|soopr|>Inspired by: [https://www.reddit.com/r/ProgrammerHumor/comments/dtitrx/was\_searching\_for\_calculator\_project\_in\_github/](https://www.reddit.com/r/ProgrammerHumor/commen...
26
programminghorror
TheZipCreator
f7zcta7
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>A perfect example of why "lines of code" is a poor metric for progress or productivity.<|eor|><|sor|>I dunno. I could have a lot of fun if I got paid by the line.<|eor|><|eols...
25
programminghorror
silenceofnight
f7z0c15
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>Why stop there? if (input == "10 * 26") printf(" = 260");<|eor|><|sor|> if (strcmp(input, "10 * 26") == 0) puts(" = 260");<|eor|><|eols|><|endoftext|>
21
programminghorror
Nick0013
f7zxluu
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>A perfect example of why "lines of code" is a poor metric for progress or productivity.<|eor|><|sor|>Well it's a good metric for "work"...<|eor|><|sor|>Nah, this was probably ...
18
programminghorror
fynn34
f80jt5c
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>A perfect example of why "lines of code" is a poor metric for progress or productivity.<|eor|><|sor|>Well it's a good metric for "work"...<|eor|><|sor|>Nah, this was probably ...
15
programminghorror
DrStalker
f80qnd7
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>Boss: All code needs to be commented. Me: /* multiplying 50 and 42 */ if (sign == "*" && num1 == 50 && num2 == 42) printf("50 * 42 = 2100") /* multiplyi...
14
programminghorror
JTC2000_Official
f7yr2su
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|sor|>This looks like the persons first project. Really wanna see how he will react in a couple of month after he had made some practice, and learned he could do it easier.<|eor|><|...
11
programminghorror
Deskilln
f7zsx54
<|sols|><|sot|>Why not rewrite that calculator in C to run faster at native speed?<|eot|><|sol|>https://i.redd.it/p0mtxzehkgz31.png<|eol|><|soopr|>Inspired by: [https://www.reddit.com/r/ProgrammerHumor/comments/dtitrx/was\_searching\_for\_calculator\_project\_in\_github/](https://www.reddit.com/r/ProgrammerHumor/commen...
11
programminghorror
Rainbow-Dev
p3xds8
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|eols|><|endoftext|>
830
programminghorror
WhiteKnightC
h8vfr6m
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>Who hurt you?<|eor|><|eols|><|endoftext|>
57
programminghorror
Ok-Cow5671
h8us1ds
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>Just why?<|eor|><|eols|><|endoftext|>
56
programminghorror
scaryAstronaut
h8vwmhm
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>They used C to create python. Now it's time to use python to create C.<|eor|><|eols|><|endoftext|>
43
programminghorror
IamImposter
h8vwtix
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>Who hurt you?<|eor|><|sor|>C++<|eor|><|eols|><|endoftext|>
40
programminghorror
PranshuKhandal
h8w9hxk
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>shouldve called it cout not p<|eor|><|sor|>or pout<|eor|><|eols|><|endoftext|>
39
programminghorror
Rhoderick
h8wbfrm
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>shouldve called it cout not p<|eor|><|sor|>std::cout<|eor|><|sor|>Well, they've also called it endl, not std::endl, so I think it's fair to say there's an implicit 'using namespace std' in there so...
30
programminghorror
RFC793
h8w1imi
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>Who hurt you?<|eor|><|sor|>Bjarne<|eor|><|eols|><|endoftext|>
28
programminghorror
nimitzhunter
h8uwnxv
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>Can you recreate meta programming too?<|eor|><|eols|><|endoftext|>
23
programminghorror
RFC793
h8w1k4k
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>Can you recreate meta programming too?<|eor|><|sor|>No. Please dont. In reality, templates are an awesome feature of C++ versus C. However, it sucks debugging or reverse engineering when you have ...
18
programminghorror
JiminP
h8vxsv9
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>Actually that's similar to what C++'s streams do; they also overload the bitshift operators as those don't have any inherent functions (other than shifting integers).<|eor|><|eols|><|endoftext|>
17
programminghorror
CSsharpGO
h8xgbng
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>Now remake python with fake c++<|eor|><|sor|>Then remake JavaScript with fake Python<|eor|><|eols|><|endoftext|>
17
programminghorror
O_X_E_Y
h8w8dy9
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>shouldve called it cout not p<|eor|><|sor|>std::cout<|eor|><|eols|><|endoftext|>
16
programminghorror
CSsharpGO
h8yiyt8
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>Now remake python with fake c++<|eor|><|sor|>Then remake JavaScript with fake Python<|eor|><|sor|>Then remake Java with fake JavaScript<|eor|><|sor|>Then remake C# with fake Java. Pretty easy, just...
11
programminghorror
Upset_Ball2495
h8yhx81
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>Now remake python with fake c++<|eor|><|sor|>Then remake JavaScript with fake Python<|eor|><|sor|>Then remake Java with fake JavaScript<|eor|><|eols|><|endoftext|>
10
programminghorror
mirandanielcz
h8wj839
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>Meta<|eor|><|sor|>Gotta love your flair<|eor|><|sor|>Test it<|eor|><|sor|>uhhh rm: it is dangerous to operate recursively on '/' rm: use --no-preserve-root to override this failsafe<|eor|>...
9
programminghorror
mirandanielcz
h8wjg0a
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>Meta<|eor|><|sor|>Gotta love your flair<|eor|><|sor|>Test it<|eor|><|sor|>uhhh rm: it is dangerous to operate recursively on '/' rm: use --no-preserve-root to override this failsafe<|eor|>...
8
programminghorror
mirandanielcz
h8w8doo
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>Meta<|eor|><|sor|>Gotta love your flair<|eor|><|eols|><|endoftext|>
7
programminghorror
mirandanielcz
h8wiwh0
<|sols|><|sot|>Recreating C++ in a language interpreted by C<|eot|><|sol|>https://i.redd.it/2jhh0ovms7h71.jpg<|eol|><|sor|>Meta<|eor|><|sor|>Gotta love your flair<|eor|><|sor|>Test it<|eor|><|sor|>uhhh rm: it is dangerous to operate recursively on '/' rm: use --no-preserve-root to override this failsafe<|eor|>...
7
programminghorror
Sire_Renart
bm667h
<|sols|><|sot|>Perhaps the best use of switch case you'll see in your life.<|eot|><|sol|>https://i.redd.it/7x4snk4z20x21.png<|eol|><|eols|><|endoftext|>
825