Integer.parse Int(bf.readLine(System.out.println("enter value for n["+m+"]:"))); can it run under this
1 2347interface X{ void m1(); void m2(); } class Child2 extends Object implements X { public void m1(){ System.out.println("Child2 M1"); } public void m2(){ System.out.println("Child2 M2"); } } public class ParentChildInfterfaceDemo { public static void main(String[] args){ X x = new Child2(); X x1 = new Child2(); x.m1(); x.m2(); x.equals(x1); } } Will the above code work? If yes? Can you please explain why the code x.equals(x1) will work as the equals method is called on interface reference vaiable?
2 4857
Difference between object and reference?
What are the various access specifiers in java?
What is variable length arguments in java?
How can you read an integer value from the keyword when the application is runtime in java? example?
What are selection structures?
Given a singly linked list, find the middle of the list in a single traversal without using temporary variable.
Is 0 an irrational number?
What is a ternary operator in java? What is an interface?
What is the inheritance?
Write a program based on Java script program.
What are the rules for naming an array?
What is method with example?
What is a default constraint?
Is it possible to cast an int value into a byte variable? What would happen if the value of int is larger than byte?
What are the uses of java?