

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!


All answers must be typed using either MS Word or an ASCII text editor and submitted to the EAGS by midnight on Friday, August 4. There will be no late extensions for this assignment. Handwritten answers will not be accepted; answers will not be accepted by methods other than the EAGS (such as e-mail). All short answer questions ("describe, "define", etc) can (and should) all be answered in one or two sentences. If you find yourself needing to write more, it probably means that you have the wrong answer. For any problem that involves computational steps, show intermediate work for partial credit.
The Honor Code is in effect for this assignment. You may consult your book, notes, or the instructor/GTA, but NOT other students (regardless of if they are in the class or not). By submitting this assignment you are pledging: "I have neither given nor received unauthorized help on this assignment."
Write the C++ code to declare an array of integers of some constant size, MAX_SIZE. Initialize each element in the array with the number of its index. For example, the first slot in the array would get a 0, the second slot would get a 1, and so on.
What is the error in the following code, and what will be the result:
char Array[10];
Array[10] = โ\0โ;
Assignment: X = Y;
Equality Test: X = = Y;
I/O: cout << X;
Arithmetic: X + Y;
Return: return (X);
Parameter: SomeFunction(X, Y);
char String1[SIZE] = "Hello World!";