(define (System.out.println x) (begin (display x) (newline) ) ) (let ( (N (read)) (ls '()) ) (let loop( (foo (read)) ) (if (eof-object? foo) (begin (set! ls (sort ls <)) (if (= (modulo N 2) 0) (System.out.println (exact->inexact (/ (+ (list-ref ls (- (/ N 2) 1)) (list-ref ls (/ N 2))) 2))) (System.out.println (exact->inexact (list-ref ls (- (ceiling (/ N 2)) 1)))) ) ) (begin (set! ls (cons foo ls)) (loop (read)) ) ) ) )