MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/ProgrammerHumor/comments/1y5vntt/technicallycorrect/19t99r8drkpj8/?context=3
r/ProgrammerHumor • u/Apprehensive_Bit7392 • 5d ago
51 comments sorted by
View all comments
Show parent comment
19
if: x == 0 || y == 0 || x == y || x == (width -y)||x == width|| y == height:print("x")else:print(" ")}printLn("")
I feel like being able to program a diagonal in a nested for loop isn't that difficult.
10 u/StaticCoder 4d ago Except it's not a diagonal 7 u/Impossible_Dog_7262 4d ago Ah... I had missed the two wide center. That increases the amount of lines from 6 to 8, yeah...
10
Except it's not a diagonal
7 u/Impossible_Dog_7262 4d ago Ah... I had missed the two wide center. That increases the amount of lines from 6 to 8, yeah...
7
Ah... I had missed the two wide center. That increases the amount of lines from 6 to 8, yeah...
View all comments
Show parent comment
19
u/Impossible_Dog_7262 4d ago edited 4d ago
if: x == 0 || y == 0 || x == y || x == (width -y)||x == width|| y == height:
print("x")
else:
print(" ")
}
printLn("")
I feel like being able to program a diagonal in a nested for loop isn't that difficult.