(define (f a b . c)
  (cond ((null? a) b)
        ((odd? b) a)
        ((> (length c) 3) (caddr c))
        (else (cdar c))))

(f 1 2 3 4 5 6)