@user21546 it works, just wasteful, not in any measurable way here, but why use space/memory you don't need to use? Anyway the requirements still seem to be a mess to me. Why is 1800 special? Because it's larger? Are there any other school ids? What are the rules when there is a school id 2100 too? Also you say "offset of 10" but 10,001 -> 100,011 is actually an offset of 90,010. Can you please get your story straight, and ask a coherent question that covers all potential edge cases? —
Aaron Bertrand ♦ 33 mins ago