I have decided. In the same way that `arr[0]` is the first entry in the array, the "first floor" of a building should mean floor 0 (at ground level) Also floor -1 is the top floor
-
-
The C standard explains that it is not undefined behaviour to stand on the roof
Show this threadThanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
Lua, Julia, and a few other programming languages go against the norm by having arrays start at 1 instead of 0. I hereby therefore declare that arrays starting at -10 are a perfectly valid choice, and thus arrays *can* have basements.
-
Look up Perl's built-in variable, `$[` https://perldoc.perl.org/perlvar.html
End of conversation
New conversation -
-
-
I thought it wraps around so that in a three-story overground building, top floor is -1, second-highest -2, ground is -3, and thus basements count down from there
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
The penthouse is the basement, therefore all buildings are toruses.
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.