Array in C++ - Quiz

  • AA collection of different data types
  • BA collection of same data type elements stored in contiguous memory
  • CA function that stores multiple values
  • DA pointer variable
  • Aint arr;
  • Bint arr(10);
  • Cint arr[10];
  • Darray int arr[10];
  • A 1
  • C-1
  • DDepends on compiler
  • Awhile loop
  • B do-while loop
  • Cfor loop
  • Dswitch loop
  • ACompiler error
  • BRuntime error always
  • CProgram stops immediately
  • DUndefined behavior
  • A int a = {1,2,3};
  • B int a[3] = 1,2,3;
  • C int a[3] = {1,2,3};
  • D int a(3) = {1,2,3};
  • ASingle array
  • B Pointer array
  • CMatrix
  • D String