daily pastebin goal
84%
SHARE
TWEET

Untitled

a guest Feb 19th, 2019 54 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ;Exercicio 1.1
  2.  
  3. (define fruta
  4. (lambda (laranjas peras)
  5.   (cond
  6.     ((> laranjas peras)
  7.      (display "laranjas maior peras"))
  8.     ((< laranjas peras)
  9.      (display "laranjas menor peras"))
  10.     ((= laranjas peras)
  11.      (if (= laranjas 0)
  12.           (display "laranjas peras iguais a zero")  
  13.       (display "laranjas peras iguais"))
  14.       ))
  15.     ))
  16.  
  17. ;Exercicio 1.2
  18. (define fruta-com-negativos
  19. (lambda (laranjas peras)
  20.   (cond
  21.     ((< laranjas 0)
  22.      -1)
  23.     ((< peras 0)
  24.      -1)
  25.     (fruta)
  26.     )))
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top