adplus-dvertising
frame-decoration

Question

Which of the following statements are correct about 6 used in the program?
int num[6];num[6]=21;

a.

In the first statement 6 specifies a particular element, whereas in the second statement it specifies a type.

b.

In the first statement 6 specifies a array size, whereas in the second statement it specifies a particular element of array.

c.

In the first statement 6 specifies a particular element, whereas in the second statement it specifies a array size.

d.

In both the statement 6 specifies array size.

Posted under C Programming

Answer: (b).In the first statement 6 specifies a array size, whereas in the second statement it specifies a particular element of array.

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. Which of the following statements are correct about 6 used in the program? int num[6];num[6]=21;

Similar Questions

Discover Related MCQs

Q. Which of the following statements are correct about an array?

1:The array int num[26]; can store 26 elements.
2:The expression num[1] designates the very first element in the array.
3:It is necessary to initialize the array at the time of declaration.
4:The declaration num[SIZE] is allowed if SIZE is a macro.

Q. O(N)(linear time) is better than O(1) constant time.

Q. For 'C' programming language

Q. What is the maximun number of dimensions an array in C may have?

Q. If x is an array of interger, then the value of &x[i] is same as

Q. If S is an array of 80 characters, then the value assigned to S through the statement scanf("%s",S) with input 12345 would be

Q. A one dimensional array A has indices 1....75.Each element is a string and takes up three memory words. The array is stored starting at location 1120 decimal. The starting address of A[49] is

Q. Minimum number of interchange needed to convert the array 89,19,40,14,17,12,10,2,5,7,11,6,9,70, into a heap with the maximum element at the root is

Q. Which of the following is an illegal array definition?

Q. Minimun number of comparison required to compute the largest and second largest element in array is

Q. The information about an array used in a program will be sorted in

Q. In which of the following cases, linked list implementation of sparse matrices consumes the same memory space as the conventional way of storing the entire array?

Q. The minmum number of inter changes needed to convert the array 89,19,40,17,12,10,2,5,7,11,6,9,70 into a heap with maximum element at the root is

Q. The  const  feature can be applied to

Q. Choose the correct statement among the following:

Q. If storage class is missing in the array definition, by default it will be taken to be

Q. Consider the array definition

int num [10] =  {3, 3, 3};

Pick the Correct answers

Q. Consider the following type definition.

typedef char x[10];

x myArray[5];

What will sizeof(myArray)  be ? (Assume one character occupies 1 byte)

Q. While passing an array as an actual argument, the function call must have the array name

Q. The following program

main( )
{
static int a[ ] = { 7, 8, 9 } ;
printf( "%d", 2[ a ] + a[ 2 ] ) ;
}