Monday, August 27, 2018

Interview Questions Of Gist Coffee For Selenium Webdriver - Business Office 2

| Monday, August 27, 2018
Part 2

6 : What is the divergence betwixt static in addition to non static variable?

Answer : Main differences are equally bellow.
  • Static variables are preceded past times static keyword. For non-static variable, at that spot is non whatsoever preceding keyword.
  • Memory is allocated for static variables at the fourth dimension of flat loading. Memory is allocated to non- static variables whenever an object is created.
  • Memory is allocated alone ane time to static variables on flat loading. Memory is allocated multiple fourth dimension whenever a novel object is created to non-static variables.
  • Static variable instance : Collage lift of students, Company lift of employees..
READ MORE close static in addition to non-static stuff.

7 : What is the divergence betwixt static in addition to non static(Instance) method?

Answer : Difference betwixt static in addition to non static method is equally bellow.
  • Method declared alongside static keyword is static method. If Method declared without static keyword in addition to therefore it is instance method.
  • No postulate of object to telephone telephone static methods. Object needed to call instance method.
  • Can non access non static materials within static methods directly. Opposite to it, We tin access static in addition to non static materials straight inside instance method.
READ MORE detail on static in addition to non-static stuff.


8 : What is inheritance inward java?

Answer : In Java, Inheritance provides machinery using which ane object of little flat tin start  all the properties in addition to behaviors of bring upwards object. It volition crate IS-A relationship. Main usage of inheritance inward coffee is for code re-usability in addition to  method overriding to laissez passer on run-time polymorphism. VIEW MORE item on inheritance.

9 : Multiple inheritance is supported inward coffee on flat level? If No.. Why?

Answer : No.. Multiple inheritance is non supported inward coffee inward instance of flat to simplify the linguistic communication in addition to cut the complexity.

10 : What is method overriding inward java?

Answer : Method overriding is a characteristic which allows a little flat or sub flat to render a specific implementation of a method which is already provided past times ane of its bring upwards classes or super class. It is used for runtime polymorphism. You tin read to a greater extent than close method overriding on THIS POST.

Related Posts