Advertisement
Guest User

Untitled

a guest
Jul 22nd, 2017
49
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.46 KB | None | 0 0
  1. package ari.com;
  2.  
  3. import java.util.Scanner;
  4.  
  5. public class Lasku {
  6. public static void main(String[] args) {
  7. Scanner lukija = new Scanner(System.in);
  8. int luku1 = 0;
  9. int luku2 = 0;
  10.  
  11. System.out.print("Anna ensimmäinen luku: ");
  12. luku1 = lukija.nextInt();
  13. System.out.print("Anna toinen luku: ");
  14. luku2 = lukija.nextInt();
  15. System.out.print("Antamiesi lukujen summa on " + (luku1 + luku2));
  16.  
  17. }
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement