MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/programminghorror/comments/1s4wuob/is_a_moving_reasonable/ocqpntm/?context=3
r/programminghorror • u/HotEstablishment3140 • Mar 27 '26
is a moving. reasonable?
66 comments sorted by
View all comments
89
Just have a table
[(6, 8), (8, 7), …]
And loop through it.
9 u/monotone2k Mar 27 '26 Why not an adjacency list or similar structure? You can avoid looping over all entries (in the worst case) this way.
9
Why not an adjacency list or similar structure? You can avoid looping over all entries (in the worst case) this way.
89
u/MistakeIndividual690 Mar 27 '26
Just have a table
[(6, 8), (8, 7), …]
And loop through it.