class Myclass { static int x=10; static int y=20; public static void main(String[] args) { display(); System.out.println("Value of static variable x= "+x); System.out.println("Value of static variable y= "+y); } static void display() { System.out.println("This is a display method"); } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)