9. [String Handling]
The String method, which results only in a positive integer, is :
(a) indexOf
(b) lastIndexOf
(c) compareTo
(d) length [Understanding]
10. [Library Classes]
The method to convert a String to double is:
(a) String. toDouble()
(b) Double. Parsedouble()
(c) Double. parseDouble(String)
(d) Double. parseDouble( ) [Understanding]
11. [Arrays]
The java statement System. out. println(x[x. length]) results in:
(a) logical error
(b) syntax error
(c) run time error
(d) no error [Analysis]
12. [Arrays]
Which of the following is a valid array declaration statement to store the Gender of 80
employees [ ‘M’-male, ‘F’-female, ‘T’-transgender ]?
(a) char gender = new char[80];
(b) char gender[] = new char[80];
(c) char gender[80];
(d) char gender[80] = new char[ ]; [Analysis]
13. [Arrays]
Arrange the following java statements in the correct order of execution to accept values
into the array a[]:
(i) a[i]=sc. nextInt( );
(ii) int a[]=new int[10];
(iii) Scanner sc=new Scanner(System. in);
(iv) for(i=0;i 10;i++)
(a) (i), (ii), (iii), (iv)
(b) (ii), (iii), (iv), (i)
(c) (iv), (iii), (ii), (i)
(d) (iii), (i), (iv), (ii)
14. [Arrays]
In the bubble sort technique, during each iteration of the inner loop, two adjacent
elements are __________and __________.
(i) compared
(ii) swapped
(iii) selected
(iv) deleted
(a) (i) and (ii)
(b) (ii) and (iii)
(c) (iii) and (iv)
(d) (ii) and (iv) [Understanding]
15. [Arrays]
What is the highest index of any array with 100 elements?
(a) 100
(b) 101
(c) 99
(d) 98 [Recall]
16. [User Defined Methods]
Mr. Sanjay is an event manager, he plans and allots duties to each of his subordinates
to handle different events. In a program, a task is divided into simple methods. Name
the feature used in these contexts.
(a) Complexity
(b) Modularity
(c) Reusability
(d) Monolithic [Understanding & Analysis]
17. [Input in Java]
Raj was asked to accept the phone number which has 10 digits, using the appropriate
method of Scanner class. Which of the following statement he must choose?
(a) Ob. nextInt()
(b) Ob. nextDouble()
(c) Ob. nextLong()
(d) Ob. next().chatAt(0) [Analysis]
18. [String Handling]
Raj wanted to count the number of digits in a given number without using a loop.
Which of the following statements is correct to perform the above?
(a) String.valueOf(n).length()
(b) Integer.parseInt(n).length()
(c) n.length()
(d) All the above [Analysis]
icse 2025 computer applications sample paper solution,icse 2025 computer applications exam pattern,icse 2025 computer applications specimen paper,computer applications,computer applications icse specimen paper,icse computer revision 2025,icse computer apllications,computer application question paper 2025,icse computer applications important questions 2023,icse 2022 computer applications important question,computer applications sample paper solved
Информация по комментариям в разработке