Computer Science, asked by afzal7790, 4 months ago

Give the output with dry run
import java.io.*;
class Q1
{
public static void main (String[]args)

{
int a = 10;
int b = 20;
int c = ++a + ++b + --a + --b;
System.out. println(++c) ;
}
}

Answers

Answered by amrapalidas1967
0

Answer:

c=63

Explanation:

c= 11(++a => ++10=11) + 21(++b => ++20=21)+10(--a=>--11=10)+20(--b=>--21=20)

c=11+21+10+20

c=60

print(++c = ++62 = 63)

Similar questions