Does Swift not have a built-in / stdlib modulus operator, such that e.g. -5 mod 3 gives 1 (instead of -2, as -5 % 3 does)?
It’s easy enough to add it, but…given the language’s careful attention to “remainder” versus “modulus” in its named functions and its docs, it really seems like something that should be in the lang!