Ask Question
3 April, 12:58

Assume that array1 and array2 are both 25-element integer arrays. Indeicate whether each of the following statements is legal or illegal. a. array1 = array2; b. cout<>array2;

+2
Answers (1)
  1. 3 April, 13:09
    0
    a. array1 = array2; Illegal

    b. cout<< array1; Illegal

    c. cin >>array2; Illegal

    Explanation:

    a. array1 = array2;

    Illegal, since the assignment operator doesn't work to directly assign the values into other array.

    b. cout<< array1;

    Illegal, since the index number in not defined, if you want to print all the elements in the array1 then run a for loop to iterate over the entire loop.

    c. cin >>array2;

    Illegal, since the index number is not defined, if you want get input from the user then run a for loop to iterate over the entire loop.
Know the Answer?
Not Sure About the Answer?
Get an answer to your question ✅ “Assume that array1 and array2 are both 25-element integer arrays. Indeicate whether each of the following statements is legal or illegal. ...” in 📙 Engineering if there is no answer or all answers are wrong, use a search bar and try to find the answer among similar questions.
Search for Other Answers