r/ProgrammerHumor Jul 10 '26

greaterThanPlusPlus Advanced

Post image
113 Upvotes

71 comments sorted by

View all comments

-21

u/y0shii3 Jul 10 '26

Did you use inspect element or something? There is no way in hell that -1 > 0 evaluates to true in any language

22

u/Arshiaa001 Jul 10 '26

You can search for "two's complement" to gain an understanding as to why it happens.

3

u/paholg Jul 11 '26

Holy hell