KnowledgeBoat Logo

Output Questions for Class 10 ICSE Computer Applications

  • Java String Handling

    If:
    String x = "Computer";
    String y = "Applications";

    What do the following function returns?

    System.out.println(x.equals(y));

    View Answer

    32 Likes


  • Java String Handling

    If:
    String x = "Computer";
    String y = "Applications";

    What do the following function returns?

    System.out.println(x.substring(1,5));

    View Answer

    38 Likes


  • Java String Handling

    Predict the output of the following Java program snippet:

    
    String S1 = "Computer World";
    String S2 = "COMPUTER WORLD";
    String S3 = "Computer world";
    String S4 = "computer world";
    System.out.println(S1 + " equals "+ S2 + " " + S1.equals(S2)); 
    System.out.println(S1 + " equals "+ S3 + " " + S1.equals(S3)); 
    System.out.println(S1 + " equals "+ S4 + " " + S1.equals(S4)); 
    System.out.println(S1 + " equalsIgnoreCase "+ S4 + " " + S1.equalsIgnoreCase(S4));
    
    View Answer

    40 Likes


  • Java String Handling

    Predict the output of the following Java program snippet:

    
    String str = "Information Technology";
    int p;
    p = str.indexOf('n');
    System.out.println(p);
    
    View Answer

    30 Likes


  • Java String Handling

    If:
    String x = "Computer";
    String y = "Applications";

    What do the following function returns?

    System.out.println(x.indexOf(x.charAt(4)));

    View Answer

    44 Likes


  • Java String Handling

    Give the output of the following string functions:

    "DEDICATE".compareTo("DEVOTE")

    View Answer

    81 Likes


  • Java String Handling

    Predict the output of the following Java program snippet:

    
    boolean p;
    p = ("BLUEJ".length() > "bluej".length()) ? true: false;
    
    View Answer

    29 Likes


  • Java String Handling

    If:
    String x = "Computer";
    String y = "Applications";

    What do the following function returns?

    System.out.println(y + x.substring(5));

    View Answer

    24 Likes


  • Java String Handling

    Predict the output of the following Java program snippet:

    
    String str1 = "Information Technology"; 
    String str2 = "information technology"; 
    boolean p = str1.equalsIgnoreCase(str2); 
    System.out.println("The result is " + p);
    
    View Answer

    26 Likes


  • Java String Handling

    What do the following functions return?

    
    String x = "Vision";
    String y = "2020";
    System.out.println(x + y);
    
    View Answer

    28 Likes


Showing 71 - 80 of 147 Questions