;; Jouw versie
(define (merge-n lst1 lst2 n)
  (define (get-sublist lst a)
    (if(or (= a 0) (null? lst))
       '()
       (cons (car lst) (get-sublist (cdr lst) (- a 1)))))
  
  (define (get-remainder lst a)
    (if(or (= a 0) (null? lst))
       lst
       (get-remainder (cdr lst) (- a 1))))
  
  (if (or (null? lst1) (null? lst2))
      (cond
        ((null? lst1) lst2)
        ((null? lst2) lst1))
      (append (get-sublist lst1 n) (get-sublist lst2 n) (merge-n (get-remainder lst1 n) (get-remainder lst2 n) n))))

;; Andere versie
(define (merge-n lst1 lst2 n)
  (define (get-sublist lst a)
    (if(or (= a 0) (null? lst))
       '()
       (cons (car lst) (get-sublist (cdr lst) (- a 1)))))
  
  (define (get-remainder lst a)
    (if(or (= a 0) (null? lst))
       lst
       (get-remainder (cdr lst) (- a 1))))

  (define (loop)
    (if (or (null? lst1) (null? lst2))
        (cond
          ((null? lst1) lst2)
          ((null? lst2) lst1))
        (append (get-sublist lst1 n) (get-sublist lst2 n) (merge-n (get-remainder lst1 n) (get-remainder lst2 n) n))))
  (loop))