Class:
Class is a collection of datamembers and methods.
Ex:
class Student {
Integer no;
String name;
Public void getDetails(){
System.debug(no);
System.debug(name);
}
}
class Employee{
String department;
void show(){
//Write the logic
}
}
Class is a collection of datamembers and methods.
Ex:
class Student {
Integer no;
String name;
Public void getDetails(){
System.debug(no);
System.debug(name);
}
}
class Employee{
String department;
void show(){
//Write the logic
}
}
No comments:
Post a Comment