3 ms·
But it seems to be weirder than that, according to the game (can someone explain this to me?): start:1, end:4 = 1,2,3 (start-inclusive, end-exclusive) start:5
by Cpoll 8y ago
But it seems to be weirder than that, according to the game (can someone explain this to me?):
start:1, end:4 = 1,2,3 (start-inclusive, end-exclusive)
start:5, end:2 = 2,3,4 (I guess this means right-exclusive, whether it's 'start' or 'end'?)
start:1, end:-2 = 1,2,3,4 (the puzzle text says -1 is the first grid-line from the right, i.e. 5, but that doesn't follow, because now it's right-inclusive)
start:-3 = 4 (so -1 is grid count+1, which explains the above?)
- thefifthsetpin 8y agoI'm with you, this feels very weird to me. Usually you get a reasonable relationship between zero- and one-indexed views of the same thing. The relationship is normally that the zero-indexed points 0 and 1 form the start and end bounds of the 1st item. CSS grid numbers columns 1, 2, 3 and also number the the lines around those columns 1,2,3,4. https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Grid_Layout/Basic_Concepts_of_Grid_Layout#Grid_lines https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Grid_La... Having grid line 1 come before column 1 makes it feel like the grid lines are substantial and the columns are merely the bounds between grid lines.
- Izkata 8y ago> Having grid line 1 come before column 1 makes it feel like the grid lines are substantial and the columns are merely the bounds between grid lines. Correct. And IIRC the spec doesn't even have columns (they're just referenced to help understanding), just column bounds.
- kristopolous 8y agoIsn't there some presumed universal convention for how to index things, present in the most popular programming languages, that avoid all of these issues that would have really easy to code? I feel like I'm spending my time doing the wrong things ... I should have been arguing for sensibility during the standards writing. These modern css things are only here to make things easier, not more wonky and strange - we already have that. If they're just dedicated to inventing new bizarreness to replace the older wackiness, where have we actually come?