(let loop[[n (read)][4? #f][6? #f]] (cond [(zero? n) (print (if (and 4? 6?) "Beautiful" "..."))] [(= 4 (mod n 10)) (loop (quotient n 10) #t 6?)] [(= 6 (mod n 10)) (loop (quotient n 10) 4? #t)] [else (loop (quotient n 10) 4? 6?)]))