Q301
Open questionWhich of these is a method can generate a boolean output?
Select an option to see the answer and solution.
Practice every MCQ with options. Use Show answers when you want the correct option and solution.
309
Questions
16/16
Page
Pick an option on a question to see the right answer and solution.
Q301
Open questionSelect an option to see the answer and solution.
Q302
Open questionclass Output
{
public static void main(String args[])
{
char a[] = {'a', '5', 'A', ' '};
System.out.print(Character.isDigit(a[0]) + " ");
System.out.print(Character.isWhitespace(a[3]) + " ");
System.out.print(Character.isUpperCase(a[2]));
}
}Select an option to see the answer and solution.
Q303
Open questionSelect an option to see the answer and solution.
Q304
Open questionSelect an option to see the answer and solution.
Q305
Open questionint a = random.nextInt(7) + 4;Select an option to see the answer and solution.
Q306
Open questionSelect an option to see the answer and solution.
Q307
Open questionimport java.util.*;
class LOCALE_CLASS
{
public static void main(String args[])
{
Locale obj = new Locale("INDIA") ;
System.out.print(obj.getCountry());
}
}Select an option to see the answer and solution.
Q308
Open questionclass Output
{
public static void main(String args[])
{
String x = Boolean.toString(false);
}
}Select an option to see the answer and solution.
Q309
Open questionclass X
{
int a;
double b;
}
class Y extends X
{
int c;
}
class Output
{
public static void main(String args[])
{
X a = new X();
Y b = new Y();
Class obj;
obj = b.getClass();
System.out.print(obj.isInstance(a));
}
}Select an option to see the answer and solution.