Computer Science, asked by geetanagar2509, 3 months ago

WAP to swap to two numbers.

Answers

Answered by priya7668
1

Answer:

Hey,here is your answer...

But I'm writing only main program...

//to input no.

System.out.print( "Input two digit no." )

int n=Integer.parseInt(br.readline());

// to get first no.

int a =n%10

n=n/10;

// to get second no.

int b= n;

int c= b*10+a;

//to print

System.out.print(+c);

HOPE IT WILL HELP !

Similar questions