Java Questions For Selenium WebDriver Interview

Part 5 21 : Explain System.out.println(); Answer : System : is a final class in  java.lang package. out : is a static member of system class. It is an instance of java.io.PrintStream. This stream is already open and ready to accept output data. println : is a method of java.io.PrintStream .It is an overloaded method. 22 : Write program to print fibonacci series 0, 1, 1, … Read more

Frequently Asked Java Interview Questions Part – 4

Part 4 16 : Can we overload static methods?  Answer : Yes.. There is not any restriction to overload static methods. We can overload static and non static methods in java. VIEW MORE on overloading in java. 17 : Can we use private member of parent class in sub class? Answer : No.. It will not allow to use private … Read more

Core Java Interview Questions For Selenium WebDriver – Part 3

Part 3 11 : Why main method is static? Answer : As we know, We can access static stuff without creating object of class. Because of static keyword with main method, Java virtual machine can directly call it without creating object of class. This way it will provide kind of root to start execution of program. 12 : What is … Read more

Interview Questions Of Core Java For Selenium WebDriver – Part 2

Part 2 Core java interview questions for selenium automation testing 6 : What is the difference between static and not static variable? Answer : Main differences are as bellow. Static variables are preceded by static keyword. For non-static variable, there is not any preceding keyword. Memory is allocated for static variables at the time of class loading. Memory is … Read more