programming languages Online Quiz - 180
Description: programming languages Online Quiz - 180 | |
Number of Questions: 20 | |
Created by: Aliensbrain Bot | |
Tags: programming languages |
The parameter Id of the field will be mentioned at what level?
What is T-code for Database Utility?
REPORT ZTEST. statics: a(3) type c value ‘10’. data: b(3) type c value ‘10’. Do 5 times. perform add using a b. enddo. write: a,b. form ADD using a b. if sy-index eq 3. exit. else. a = a + 1. b = b + 1. endif. endform. " ADD What is the values of a and b?
Which is the most suitable Java collection class for storing various companies and their stock prices? It is required that the class should support synchronization inherently.
Which of the following statements is not true about threads?
Select the new keyword since J2SE 1.4
Assume the bit pattern of byte x is: 10110001. What will the sign of x be after x>>2?
What happens when you compare two primitives of different numerical types?
All exceptions inherit from
package polymorphism; class TestSup { static int p = 100; } public class TestPoly extends TestSup { public static void main(String[] args) { TestPoly TP = new TestPoly(); TP.p = 400; TestSup TS = new TestSup(); TS.p = 100; TestSup TSP = new TestPoly(); TSP.p = 500; System.out.print("TestSup = " + TestSup.p); System.out.print(" ,TestPoly = " + TestPoly.p); System.out.print(" ,TP = " + TP.p); System.out.print(" ,TS = " + TS.p); System.out.print(" ,TSP = " + TSP.p); } }
package polymorphism; class TestPolymorphismSuper { int p; TestPolymorphismSuper testPoly() { TestPolymorphismSuper TS = new TestPolymorphismSuper(); TS.p =100; return TS; } } public class TestPolymorphism1 extends TestPolymorphismSuper{ TestPolymorphism1 testPoly() { TestPolymorphism1 TSub = new TestPolymorphism1(); TSub.p =500; return TSub; } public static void main(String[] args) { TestPolymorphismSuper TSuper = new TestPolymorphism1(); TSuper = TSuper.testPoly(); System.out.println(TSuper.p); } }
package polymorphism; class TestSuperr { double TestPoly(long a, float b, int c) { return ((a + b) * c); } } public class TestPolym extends TestSuperr { double TestPoly(long a, double b, int c) { return (a + b + c); } public static void main(String[] args) { TestSuperr TSU = new TestPolym(); double p = TSU.TestPoly(11, 9, 10); System.out.print("p = " + p); p1 = TSU.TestPoly(11, 9.0, 10); System.out.print(" ,p1 = " + p1); } }
package exceptions; public class TestException4 { static String trimString(String x) { return x.trim(); } public static void main(String[] args) { try { String s = trimString(" tcs "); System.out.println("s = "+s); } finally { System.out.println("In finally"); } } }