Posted By

PabloBentezMolina on 07/13/11


Tagged

peso piedra mayor


Versions (?)

Piedra de mayor peso


 / Published in: Ruby
 

El programa dice cual es la piedra de mayor peso

  1. piedra1 = 40
  2. piedra2 = 12
  3.  
  4. if piedra1 > piedra2
  5. puts "piedra1 pesa mas"
  6. elsif piedra1 == piedra2
  7. puts "los dos pesan igual"
  8. else
  9. puts"piedra2 es la mayor peso"
  10. end

Report this snippet  

You need to login to post a comment.