ICSE Class 10 Java Arrays: A Dry-Run Guide for 2027
Practise ICSE Class 10 Java arrays with original dry runs for searching, sorting and matrix sums, plus a focused seven-session revision plan for 2027.

Can you recognise an array program but struggle to write one when the numbers or wording change? For ICSE Class 10 Computer Applications preparation, that is a useful warning: you may remember the layout without understanding what each loop does. This guide builds a repeatable dry-run method for Java arrays using original practice examples. Students in Behala and Kolkata can work through it in short sessions alongside school revision. The aim is to explain every index, comparison and update before relying on the computer to tell you whether an answer is correct.
Start with the array skills in the 2027 syllabus
The CISCE Computer Applications syllabus for Examination Year 2027 includes one-dimensional and two-dimensional arrays. Its Class X array scope names bubble sort, selection sort, linear search and binary search; sorting and searching are specified for single-dimensional arrays. For two-dimensional arrays, it includes input, display and sums of rows, columns and diagonals. These are skills to practise, rather than predictions of particular questions.
Use the official syllabus linked below alongside the copy supplied by your school. This article concentrates on array reasoning; it does not replace revision of the rest of Computer Applications. All examples here are original practice tasks, not CISCE questions or an official marking scheme. Follow the instructions printed on your actual school or board paper.
Separate the index, the value and the answer
Draw an array as boxes before writing a loop. For the values 14, 9, 14, 22 and 6, write indices 0, 1, 2, 3 and 4 underneath. The value at index 3 is 22; the third value is 14 at index 2. Saying these aloud exposes the difference between a position in ordinary language and a Java index.
Oracle’s Java documentation confirms that array length is fixed when the array is created and indexing starts at zero. For an array named a, use a.length for its number of elements. A traversal beginning at zero normally continues while i < a.length. Using i <= a.length attempts an extra access beyond the last valid index.
Give each working variable a clear job. An index identifies a location; a total accumulates values; a counter records how many items satisfy a condition. If a question asks for both the number and sum of values above a threshold, one variable cannot represent both answers.
Dry-run a conditional total before coding
Original task: using 14, 9, 14, 22 and 6, find the number and total of values strictly greater than 10. Begin with count = 0 and total = 0. Make four notebook columns: index, current value, count after checking, and total after checking. Record one row for every iteration, including values that fail the condition.
At index 0, value 14 changes the count to 1 and total to 14. Value 9 leaves both unchanged. The next 14 gives count 2 and total 28. Value 22 gives count 3 and total 50; the final 6 changes nothing. Your output should therefore report three qualifying values with total 50.
Now change the threshold to 14. Because the instruction says strictly greater, only 22 qualifies. If your revised trace includes either 14, you have changed the meaning of the question. Add a second test where no value qualifies; both accumulators should remain zero. This checks the condition and initial values independently.
Choose a search method from the data
For linear search, inspect values one by one. In the same unsorted array, searching for 22 reaches index 3. Searching for 14 raises an extra question: does the task require the first occurrence, every occurrence or a frequency? A first-match search can stop at index 0; a frequency count must continue and return two.
Binary search needs sorted data with comparison logic that matches its order. Oracle’s Arrays documentation explicitly requires sorted input for its binarySearch methods. Do not apply the usual ascending-order classroom algorithm to an arbitrary unsorted list. Also, sorting changes positions: an index in the sorted array may differ from the original index.
Try an ascending array containing 6, 9, 14, 22 and 31. To find 22, start with low = 0 and high = 4. Integer midpoint 2 gives 14, so move low to 3. The next midpoint is 3, which contains 22. For a missing target of 20, the same first update is followed by high = 2; low is then greater than high, so the search ends unsuccessfully. Trace low, high and mid on separate columns.
Explain one sorting pass without memorising a page
Take the original practice list 18, 7, 12 and 5. In a left-to-right bubble-sort pass for ascending order, compare neighbouring values and swap when the left value is larger. After comparing the first pair, the list becomes 7, 18, 12, 5. The next comparison gives 7, 12, 18, 5; the final comparison gives 7, 12, 5, 18.
That first pass has placed the largest value at the right end, but the entire array is still not sorted. In selection sort, the first pass instead locates the smallest value in the unsorted region and swaps it into the first position, giving 5, 7, 12, 18 for this example. The different intermediate lists show why you must identify the algorithm before tracing it.
Practise with repeated values and an already sorted list too. For each inner loop, explain which pair is compared and why the index remains valid. When a task asks you to implement a particular sorting technique, demonstrate that technique rather than substituting a library call.
For matrix sums, decide where the total resets
Use an original 3-by-3 matrix with rows [2, 5, 1], [4, 3, 6] and [7, 0, 8]. Its row totals are 8, 13 and 15; its column totals are 13, 8 and 15. To calculate each row separately, reset the row total inside the outer row loop, before the inner column loop starts. Resetting it outside both loops produces a running total across rows.
For the main diagonal, the row and column indices match: 2 + 3 + 8 = 13. For the opposite diagonal, select positions whose indices add to 2: 1 + 3 + 7 = 11. More generally, for a square matrix of size n, the opposite diagonal uses column n - 1 - row. Draw the cells you intend to include before writing the expression.
If asked for a combined total of both diagonals, read whether the centre should be counted once. Adding the two diagonal totals here gives 24, which includes the middle 3 twice. The sum of distinct diagonal cells is 21. This is a wording check, not an assumption to make for every matrix question.
Use seven short sessions to make the reasoning stick
Treat the following as a suggested practice sequence, adjusting it to your school workload. Begin each session by tracing a small example on paper. Write the program afterwards, predict the output, then run it in your school’s Java environment. When output differs, locate the first trace row where your prediction and program disagree.
- Session 1: label indices and write an input-and-display traversal.
- Session 2: practise conditional counts and totals, including a no-match case.
- Session 3: implement linear search for a first match and then a frequency.
- Session 4: trace binary search for a present and an absent target in sorted data.
- Session 5: compare bubble-sort and selection-sort intermediate arrays.
- Session 6: calculate matrix row, column and diagonal sums with explicit resets.
- Session 7: solve a fresh mixed task without notes and explain the test cases.
Ask for feedback on the failing step
Parents can help without learning Java syntax: ask the student what each variable means and how they know the last element was checked. A useful explanation connects an instruction to a trace row and an expected result. A copied program that runs once does not establish that the student can adapt it.
If you need help in Behala, bring one attempted program, its input, your expected output and the output you obtained to Path Creator Tutorials. Discuss the specific concept you want to strengthen and ask which learning option suits your school level. The site’s Core Java page provides a starting point for that conversation; confirm the current syllabus match and class arrangements directly.
Quick answers
Common questions
Which array topics should I practise for ICSE Computer Applications 2027?
The official Class X scope includes single-dimensional sorting and searching, plus two-dimensional input, display and row, column and diagonal sums. Check the current CISCE syllabus and your school guidance; this guide covers array practice rather than the complete subject.
Can binary search work on an unsorted array?
The usual ascending-order binary search requires ascending sorted input. Its decision to discard half the search region depends on that order. Use linear search for an unsorted list, or sort first when the task permits and original positions are not required.
What should an array dry-run table contain?
Record the iteration or index, the current value and every variable that changes. For binary search, include low, high and mid. For sorting, show the array after each requested comparison or pass, following the question’s wording.
Why do my matrix row sums keep increasing?
Check where the accumulator resets. For separate row totals, initialise it to zero at the start of each outer row iteration, before traversing the columns. A reset outside both loops accumulates values from earlier rows.
Should I practise Java arrays on paper or on a computer?
Use both. Predict a small example on paper, write the program and run it, then compare the actual output with your prediction. Finally change the input or condition and solve again without copying the earlier answer.
Verified references