Implement caesar(text, shift) that shifts each letter by shift positions in the alphabet, wrapping around and preserving case. Other characters are unchanged. Negative shifts and shifts larger than 26 must work.
Also implement crack(ciphertext): try all 26 shifts and return the shift (0–25) that decrypts the text into the version with the most occurrences of the letter e (case-insensitive); ties go to the smallest shift.