Guest User

Untitled

a guest
Jun 22nd, 2018
97
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.63 KB | None | 0 0
  1. /*
  2. * To change this template, choose Tools | Templates
  3. * and open the template in the editor.
  4. */
  5.  
  6. package javaapplication14;
  7.  
  8. /**
  9. *
  10. * @author locks
  11. */
  12. public class Main {
  13.  
  14. /**
  15. * @param args the command line arguments
  16. */
  17. public static void main(String[] args) {
  18. // TODO code application logic here
  19. int numero = 43;
  20. String resultado = numero + " igual a " + (numero*1.6215);
  21. System.out.println(resultado);
  22. System.out.println( conversao(numero) );
  23. }
  24.  
  25. public static String conversao(int v) {
  26. return v + " milhas igual a " + v*1.6125;
  27. }
  28.  
  29.  
  30. }
Add Comment
Please, Sign In to add comment