मराठी

Rupa Pandit solutions for कम्प्युटर एपलीकेशंस [इंग्रजी] इयत्ता १० आयसीएसई chapter 7A - Arrays - One Dimension [Latest edition]

Advertisements

Chapters

Rupa Pandit solutions for कम्प्युटर एपलीकेशंस [इंग्रजी] इयत्ता १० आयसीएसई chapter 7A - Arrays - One Dimension - Shaalaa.com
Advertisements

Solutions for Chapter 7A: Arrays - One Dimension

Below listed, you can find solutions for Chapter 7A of CISCE Rupa Pandit for कम्प्युटर एपलीकेशंस [इंग्रजी] इयत्ता १० आयसीएसई.


Exercises
Exercises [Pages 172 - 177]

Rupa Pandit solutions for कम्प्युटर एपलीकेशंस [इंग्रजी] इयत्ता १० आयसीएसई 7A Arrays - One Dimension Exercises [Pages 172 - 177]

Choose the correct option.

1. (i)Page 172

A single dimensional array has N elements in it. What is the last subscript?

  • N

  • N+1

  • 0

  • N−1

1. (ii)Page 172

Given:

int a[ ] = new int [5];//declaration of array

a[3]=5;

The code will generate ______.

  • no error

  • logical error

  • syntax error

  • runtime error

1. (iii)Page 172

Identify the true statement.

  • All elements in an array of different datatype.

  • Some elements in an array of same datatype.

  • All elements in an array are of same datatype.

  • he first element in an array is of different datatype from the other elements.

1. (iv)Page 172

Given:

int car[]= new int [10];

The name of the array is ______.

  • int

  • car

  • new

  • 10

1. (v)Page 172

Given:

int n = 0;
int ar[] = new int [n];
ar[0] =25;
System.out.print(" ar0] =“ + ar[0]);

The code will generate ______.

  • no error

  • logical error

  • syntax error

  • runtime error

1. (vi)Page 173

Given:

int ta[ ] = {11, 22, 33, 44, 55};
ar[3]+= ar[2];
System.out.print(“ ar[3]=" + ar[3]);

The output will be ______.

  • ar[3]=44

  • ar[3]=33

  • ar[3]=55

  • ar[3]=77

1. (vii)Page 173

Given:

int KH[] = {0, 0, 0, 0, 0, 0}
int len = KH.length;
system.out.print("array length="+len);

The output will be ______.

  • array length = 6

  • array length = 0

  • array length = 7

  • array length = 5

1. (viii)Page 173

Given:

int AM[]= {3, 6, 12, 24, 48 96};
for (int p= 3; p<6 ; p++)
System.out.print ("*" + AM[p]/2);

The output will be ______.

  • * 6 * 12 * 24 * 48

  • * 12 * 24 * 48

  • 12 * 24 * 48 *

  • * 24 * 48 * 96

1. (ix)Page 173

Identify the false statement.

  • The index of an array begins with 0.

  • An Array occupies contiguous memory locations.

  • An array is a collection of multiple variables of different data types.

  • The [] brackets in the declaration statement indicates the size of the array.

1. (x)Page 173

Given:

int PM[] = {650, 525, 475, 325, 250, 175 };
for (int p = 5; p>=1 ; p--)
System.out.print (" % “ + PM[p]%100);

The output will be ______.

  • % 50, %2 5, %75, %25, %50, %75

  • % 75 % 50 % 25 % 75 % 25

  • 75 % 50 % 25 % 75% 25%

  • % 175 % 250 % 325 % 475 % 525

1. (xi)Page 174

Java statement to access the 5th element of an array is:

  • X[4]

  • X[5]

  • X[3]

  • X[0]

Answer the following in brief.

2. (i)Page 174

What is the use of an array?

2. (ii)Page 174

What is the use of keyword ‘new’?

2. (iii)Page 174

What is the difference between static and dynamic allocation?

3. (i)Page 174

Some of the code given below contains errors. Identify the error and correct it. Write the output of the correct/corrected code.

int ad[] = {25, 5, 45, 4, 92, 2, 29, 9};
int ap = (ad[0] + ad[7]) /ad[5];
System.out.print(" Result =" + ap);
3. (ii)Page 174

Some of the code given below contains errors. Identify the error and correct it. Write the output of the correct/corrected code.

int CQ[] = {10, 20, 30};
CQ[0]++; CQ[1]+; CQ[3]++;
      for(int j = 0; j <3; j++)
System.out.print (""+ CQ[j]);
3. (iii)Page 174

Some of the code given below contains errors. Identify the error and correct it. Write the output of the correct/corrected code.

int LP[] = {11, 44, 77, 33, 55);
for(int j = 0; j <= 4; j++)
LP[j] += j;
3. (iv)Page 174

Some of the code given below contains errors. Identify the error and correct it. Write the output of the correct/corrected code.

double KB[] = {3.12, 4.64, 5.57, 6.23, 7.25};
for( int j=0; j<= 5; j++)
KB[j] = (int)KB[j];
System.out.print("KB[2] =" + KB[2]);
3. (v)Page 174

Some of the code given below contains errors. Identify the error and correct it. Write the output of the correct/corrected code.

double FZ[] = {3.12, 4.64, 5.57, 6.23, 7.25);
boolean asc = true;
for( int j = 0; j<= 3; j++)
{
     if(FZ[j] >FZ[j+1])
     {
         asc = false;
     }
}
System.out.print(" ASC =" + asc);
3. (vi)Page 174

Some of the code given below contains errors. Identify the error and correct it. Write the output of the correct/corrected code.

int GY[] = {3.12, 4.64, 5.57, 6.23, 7.25};
boolean desc = true;
for(int j = 0; j<=3; j++)
 {
    if(GY[j]>GY[j+1])
    {
        desc = false;
     break;
 }
}
3. (vii)Page 175

Some of the code given below contains errors. Identify the error and correct it. Write the output of the correct/corrected code.

int YM[] = { 512, 312, 452, 652, 782};
boolean all = true;
for(int j = 0; j <5; j++)
{
   if(YM[j]%10 !=2)
   {
      all = false;
   }
}
System.out.print(" ALL =" + all);
3. (viii) (a)Page 175

Some of the code given below contains errors. Identify the error and correct it. Write the output of the correct/corrected code.

int MW[ ] = {21, 56, 31, 459, 52, 742, 26};
boolean some = false;
for(int j = 0; j <MW.length; j++)
{
    if (MW[j]/100 > 0)
    {
        System.out.print("Some Value is :" + MW[j]);
        some = true;
        break;
    }
}
System.out.print(" SOME = " + some);
3. (viii) (b)Page 175

Some of the code given below contains errors. Identify the error and correct it. Write the output of the correct/corrected code.

In the above code h(i),

replace the array by

int MW[] = {56, 21, 33, 78, 95};

3. (ix)Page 175

Some of the code given below contains errors. Identify the error and correct it. Write the output of the correct/corrected code.

int ZR[] = {0, 0, 0, 0, 0, 0, O};
ZR[0] = 2;
for(int j =1; j < ZR.length; j++)
{
      ZR[j] = ZR[j -1] * 2;
}
System.out.print(" The array is : ");
for(int j = 0; j < ZR.length; j++)
      System.out.print (" " + ZR[j]);

3. (x)Page 175

Some of the code given below contains errors. Identify the error and correct it. Write the output of the correct/corrected code.

int HC[ ] = {1, 2, 3, 4, 5, 6};
int n = HC.length -1;
for(int j = 0; j <=n/2; j++)
{
    HC[j] = HC[n-j];
System.out.println(" The array is: ");
for( intj = 0; j <HC.length; j++)
System.out.print("" + HC[j]);
3. (xi)Page 176

Some of the code given below contains errors. Identify the error and correct it. Write the output of the correct/corrected code.

int WH[] = {11, 22, 33, 44, 55, 66, 77};
int n = WH.length -1;
for(int j = 0; j<=n/2; j++)
{
    int tmp = WH[j];
    WH[j] =WH[n - j];
    WH[j] =WH[n - j];
}
System.out.print(" The array is: ");
for(int j = 0; j<WH.length; j++)
    System.out.print(" " + WH[j]);
3. (xii)Page 176

Some of the code given below contains errors. Identify the error and correct it. Write the output of the correct/corrected code.

int DL[ ] = new int [5];
int n = 5;
for(int j = 0; j<=n; j++)
    System.out.print(" " + DL[j]);
4. (i)Page 176

Write a program for the following.

Create an array AW[ ] of type int and size 8 and fill it with variables. Print those elements which have last digit 3.

For example:

Input 33 87 35 8 183 21 76 403 539
Output 33 183 403
4. (ii)Page 176

Write a program for the following.

Create an array DW[ ] of type double and size 8 and fill it with variables. Calculate the average of the maximum and the minimum element.

For example:

Input 30.8 27.5 18.2 35.2 21.1 25.6 8.8 9.4
Output Max = 35.2 Min = 8.8 Average = 22.0  
4. (iii)Page 176

Write a program for the following.

Fill two arrays TA[ ] and TB[ ] of size 7 and type integer each. Create a third array TC[ ] that contains the elements of the second array (TB[ ]) followed by the elements of the first array (TA [ ]).

Input TA[ ] 21 31 41 51 61 23 43
  TB[ ] 28 38 48 58 68 78 16
Output TC[ ] 28 38 48 58 68 78 16
  21 31 41 51 61 23 43
4. (iv)Page 177

Write a program for the following.

Create an array ZR[] of type int and size 10 and fill it with variables. Create another array NZR[ ] that contains only the non zero elements of array ZR[ ].

For example:

Input ZR[ ] 100 405 84 0 25 0 0 45 0 0
Output NZR[ ] 100 405 84 25 45
4. (v)Page 177

Write a program for the following.

Create an array RW[ ] of type int and size 8 and fill it with variables. Create another array EW[ ] that contains the even elements of RW[ ] in front followed by the odd elements.

For example:

Input RW[ ] 31 45 62 87 54 29 83 44
Output EW[ ] 62 54 44 31 45 87 29 83
4. (vi)Page 177

Write a program for the following.

Create two arrays STP[ ] and STQ[ ], both of type int and size 8 and fill them with variables. Create a third array STUN[ ] that contains all the elements from both the arrays without any repetition.

For example:

Input STP[ ] 17 54 36 87 44 92 28 77        
Input STQ[ ] 72 94 44 33 77 87 17 37        
Output STUN[ ] 17 54 36 87 44 92 28 77 72 94 33 37
4. (vii)Page 177

Write a program for the following.

Create two arrays TEC[ ] and TEH[ ], both of type int and size 8 and fill them with variables. Create a third array TIN[ ] that contains only the common elements of both the arrays.

For example:

Input TEC[ ] 17 54 36 87 44 92 28 77
Input TEH[ ] 72 94 44 33 77 87 17 37
Output TIN[ ] 17 87 44 77        
5. (a)Page 177

Consider the given array and answer the question given below:

int x[ ] {4; 7,9,66,72,0,16);

What is the length of the array?

5. (b)Page 177

Consider the given array and answer the question given below:

int x[ ] {4; 7,9,66,72,0,16);

What is the value in x[4]?

Solutions for 7A: Arrays - One Dimension

Exercises
Rupa Pandit solutions for कम्प्युटर एपलीकेशंस [इंग्रजी] इयत्ता १० आयसीएसई chapter 7A - Arrays - One Dimension - Shaalaa.com

Rupa Pandit solutions for कम्प्युटर एपलीकेशंस [इंग्रजी] इयत्ता १० आयसीएसई chapter 7A - Arrays - One Dimension

Shaalaa.com has the CISCE Mathematics कम्प्युटर एपलीकेशंस [इंग्रजी] इयत्ता १० आयसीएसई CISCE solutions in a manner that help students grasp basic concepts better and faster. The detailed, step-by-step solutions will help you understand the concepts better and clarify any confusion. Rupa Pandit solutions for Mathematics कम्प्युटर एपलीकेशंस [इंग्रजी] इयत्ता १० आयसीएसई CISCE 7A (Arrays - One Dimension) include all questions with answers and detailed explanations. This will clear students' doubts about questions and improve their application skills while preparing for board exams.

Further, we at Shaalaa.com provide such solutions so students can prepare for written exams. Rupa Pandit textbook solutions can be a core help for self-study and provide excellent self-help guidance for students.

Concepts covered in कम्प्युटर एपलीकेशंस [इंग्रजी] इयत्ता १० आयसीएसई chapter 7A Arrays - One Dimension are .

Using Rupa Pandit कम्प्युटर एपलीकेशंस [इंग्रजी] इयत्ता १० आयसीएसई solutions Arrays - One Dimension exercise by students is an easy way to prepare for the exams, as they involve solutions arranged chapter-wise and also page-wise. The questions involved in Rupa Pandit Solutions are essential questions that can be asked in the final exam. Maximum CISCE कम्प्युटर एपलीकेशंस [इंग्रजी] इयत्ता १० आयसीएसई students prefer Rupa Pandit Textbook Solutions to score more in exams.

Get the free view of Chapter 7A, Arrays - One Dimension कम्प्युटर एपलीकेशंस [इंग्रजी] इयत्ता १० आयसीएसई additional questions for Mathematics कम्प्युटर एपलीकेशंस [इंग्रजी] इयत्ता १० आयसीएसई CISCE, and you can use Shaalaa.com to keep it handy for your exam preparation.

Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×