Professional Documents
Culture Documents
//data
//methods or functions
class Hello
System.out.println(msg);
**/*
Second Program
public class Calc
{
int a,b,r; //data members
a=i;
b=j;
r=a+b;
System.out.println("sum="+r);
r=a-b;
System.out.println("substraction="+r);
c1.setData(10, 20);
c1.add();
c1.sub();
output
Sum=30
Substraction=-10
Main function in java -
String arg[]: is array of string elements which main function take as parameter and it is called command line
arguments/parameters.
2- Interpreted and execute (take byte code and generate machine code of particular platform)
upadhyaydhiraj@gmail.com
9009874373
Windows 10
We need to develop interpreter (JVM ) for windows 10 to run java applications on it.
Byte code--- > JVM for windows 10- machine code for windows 10 (86 bit machine code)