fork download
  1. ; assign y
  2.  
  3. (define (solve1 a b x)
  4. (+ (* (- 1 x) a) (* x b)))
  5.  
  6. (display (solve1 13 17 0))
  7. (display " ")
  8. (display (solve1 13 17 1))
  9. (newline)
  10.  
  11. (define (solve2 a b x)
  12. (vector-ref (vector a b) x))
  13.  
  14. (display (solve2 13 17 0))
  15. (display " ")
  16. (display (solve2 13 17 1))
  17. (newline)
Success #stdin #stdout 0s 7276KB
stdin
Standard input is empty
stdout
13 17
13 17