(define d (read)) (define (readn n) (if (= n 0) '() (cons (let ( (a (read)) (b (read))) (- b a) ) (readn (- n 1)) ) )) (let ( (l (readn d)))(if (apply = l) (print (car l)) (print "-1")))