.
class Student{
int rollno;
String name;
static String college = "EWIT";
//static method to change the value of static variable
static void change(){
college = "SJBIT";
}
//constructor to initialize the variable
Student(int r, String n){
rollno = r;
name = n;
}
//method to display values
void display(){[Link](rollno+" "+name+" "+college);}
}
//Test class to create and display the values of object
public class TestStaticMethod{
public static void main(String args[]){
[Link]();//calling change method
//creating objects
Student s1 = new Student(111,"Kiran");
Student s2 = new Student(222,"Aryan");
Student s3 = new Student(333,"Sonu");
//calling display method
[Link]();
[Link]();
[Link]();
}
}