What does void returns in the code?
Anonymous Quiz
75%
It does not return anything
9%
It returns integer
2%
It returns boolean
14%
All of the above
How do all Variables pass in java?
Anonymous Quiz
50%
By values
21%
By strings
13%
By array
16%
None of the above
String variable contains a collection of characters surrounded by ..........?
Anonymous Quiz
65%
" "
9%
( )
15%
{ }
11%
[ ]
In which case would you use a FULL OUTER JOIN?
Anonymous Quiz
22%
You want all matched data from both tables
17%
Both table have NULL values
5%
You want all unmatched data from one table
27%
You want all matched and unmatched data from only one table
9%
One of the tables has more data than the other
20%
You want all unmatched data from both table
public class MyExample
{
public static int a=10;
public int b=22;
public in C=33;
}
Identify the class variable(s) in the given code snippet.
{
public static int a=10;
public int b=22;
public in C=33;
}
Identify the class variable(s) in the given code snippet.
Which is a valid statement in java?
Anonymous Quiz
52%
int i [ ] = new int[1];
13%
int i = new int;
20%
int i = new int();
15%
int i [ ] = new int();
Choose the correct option
Which of the following statement is/are true?
1) A public member is accessible wherever the containing class is accessible
2) A protected member is accessible to all the Classes within different packages
3) A private member never accessible outside the containing class
Which of the following statement is/are true?
1) A public member is accessible wherever the containing class is accessible
2) A protected member is accessible to all the Classes within different packages
3) A private member never accessible outside the containing class
Choose the correct options
Which statement is true for the class First given below?
Package myPackage;
class First
{
/* Class body*/
}
Which statement is true for the class First given below?
Package myPackage;
class First
{
/* Class body*/
}
1. import myPackage.TestClass
2. public class TestSubject
extends TestClass
3 .{
4. public TestSubject()
5. {
6. super();
7. }
8. public void getAllDetails()
9. {
10. super();
11. }
12. }
Identify the Error if any in the given code segment.
2. public class TestSubject
extends TestClass
3 .{
4. public TestSubject()
5. {
6. super();
7. }
8. public void getAllDetails()
9. {
10. super();
11. }
12. }
Identify the Error if any in the given code segment.
Refers the given pseudocode statements to print the sum of digits of number. What condition should be used in place of "?" to get desired output.
public class Program
{
public static void main(String[] args) {
int n=3678, j=0;
do
{
j=j+(n%10);
}while(?);
System.out.println(j);
}
}
public class Program
{
public static void main(String[] args) {
int n=3678, j=0;
do
{
j=j+(n%10);
}while(?);
System.out.println(j);
}
}
interface Ink{
static void pen();//line 3
}
class Color implements Ink
{
public void pen(){
System.out.println("i can write");
}
}
public class Program{ //line 12
public static void main(String[] args) {//line 14
Color c = new Color();
c.pen();//line 17
}
}
Which line in the given code will generate error?
static void pen();//line 3
}
class Color implements Ink
{
public void pen(){
System.out.println("i can write");
}
}
public class Program{ //line 12
public static void main(String[] args) {//line 14
Color c = new Color();
c.pen();//line 17
}
}
Which line in the given code will generate error?
public class Program
{
public static void main(String[] args) {
try{
int c[]={1};
System.out.println(c.length);
c[1]=142;
System.out.println("c = "+c[1]);
int a=args.length;
System.out.println("a = "+a);
int b=8/a;
}
catch(ArithmeticException e){
System.out.println("Divide by 0: "+e);
}
catch(ArrayIndexOutOfBoundsException e){
System.out.println("Array index oob: "+e);
}
System.out.println("After try/catch blocks");
}
}
Choose the correct option
What will be the output of the give code snippet after it's execution?
{
public static void main(String[] args) {
try{
int c[]={1};
System.out.println(c.length);
c[1]=142;
System.out.println("c = "+c[1]);
int a=args.length;
System.out.println("a = "+a);
int b=8/a;
}
catch(ArithmeticException e){
System.out.println("Divide by 0: "+e);
}
catch(ArrayIndexOutOfBoundsException e){
System.out.println("Array index oob: "+e);
}
System.out.println("After try/catch blocks");
}
}
Choose the correct option
What will be the output of the give code snippet after it's execution?
👍1