Computer Science, asked by chromosome, 11 months ago

write a java program!!!​

Answers

Answered by lordsupreme911
1

Answer:

class ABC

{

public static void main(String args[])

{

int a = 3;

int b = 4;

int c = a+b;

System.out.println("Sum is "+c);

}

}

Explanation:

This is a program demonstrating the addition of two numbers! Hope this helps!

Answered by mn121
1

//this is a single line comment..

/*

Multi-line comment...

This a program to print hello with your name...

*/

import java.util.*;

public class program //class name

{

public static void main (String args[])

{

Scanner in = new Scanner (System.in);

String name;

System.out.println("Enter your name: ");

name = in.nextLine();

System.out.println("Hello... "+name+"!!!");

}

}

//Hope it helps you...

Please mark it as brainliest...

☺️☺️☺️

#BAL

#AnswerWithQuality

Similar questions