% != modulo

TIL that the % operator in Swift is a remainder operator and not a true modulo operator. I expected -1 % 7 to return 6, but it returns -1.