Advertisement
WesleyVicen

Atv 2 Lista 2

Mar 27th, 2017
52
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.40 KB | None | 0 0
  1. package lista2;
  2.  
  3. import java.util.Scanner;
  4.  
  5. public class atvdois {
  6.     public static void main(String[] args){
  7.         Scanner numero = new Scanner(System.in);
  8.         System.out.println("DIgite o valor A");
  9.         int a = numero.nextInt();
  10.         System.out.println("Digite o valor B");
  11.         int b = numero.nextInt();
  12.         int aux = a;
  13.         a=b;
  14.         b=aux;
  15.         System.out.println("A Variavel 'A' é "+a+" e a 'B' é: "+b);
  16.     }
  17.  
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement