WRITE JAVA PROGRAMS FOR THE FOLLOWING.
Attachments:
Answers
Answered by
1
1.
public class subtract
{//opens the class
public static void main(String args[])
{//opens the main method
int a=4;
int b=2;
int c=a-b;
System.out.println(c);
} //closes the main method
} //closes the class
public class subtract
{//opens the class
public static void main(String args[])
{//opens the main method
int a=4;
int b=2;
int c=a-b;
System.out.println(c);
} //closes the main method
} //closes the class
Superhacks:
This is to subtract 2 numbers
Similar questions
Social Sciences,
8 months ago
Science,
8 months ago
English,
8 months ago
Science,
1 year ago
Political Science,
1 year ago
Computer Science,
1 year ago