Computer Science, asked by geetanagar2509, 7 months ago

Write a program to accept two numbers from the user (Use Scanner class) and swap them.

Answers

Answered by harshantil8930
0

Answer:

thanks sheetal rani is the gas which is the founder of the Sunday afternoon to know if it was using a full stop to know.

Answered by TheKingRJ121
13

Answer:

Java Program

1. import java.util.*;

2.class Swap_With {

3..public static void main(String[] args) {

4.int x, y, t;// x and y are to swap.

5.Scanner sc = new Scanner(System.in);

6.System.out.println("Enter the value of X and Y");

7.x = sc.nextInt();

8.y = sc.nextInt();

Hope it helps you

Please mark me as Brainliest and please follow me

Similar questions