(defun main (&rest argv) (declare (ignorable argv)) (let* ((n (read)) (a (read)) (b (read)) (c (read)) (n/a (floor n a)) (n/b (floor n b)) (n/c (floor n c)) (-n/ab (- (floor n (lcm a b)))) (-n/bc (- (floor n (lcm b c)))) (-n/ca (- (floor n (lcm c a)))) (n/abc (floor n (lcm a b c)))) (format t "~d~%" (+ n/a n/b n/c -n/ab -n/bc -n/ca n/abc)))) (main)