1) Compare the following two segments of c++ code. Predict what will be the output of each segment for various grade values. Then, use a small test program to confirm or correct your answer. Describe whether you were correct or not. If you were not correct, describe what you learned from this comparison.
Make sure you include your predictions, the values you tested, and the results of your tests in your response to this question.
2) Compare the following two segments of C++ code. Predict what will be the result of each segment for various grade values. Then, use a small test program to confirm or correct your answer (you can add another segment of code to your existing test program - just comment out the code you used for the 1st question). Describe whether you were correct or not. If you were not correct, describe what you learned from this comparison.
if (grade = 100) if (grade == 100)
cout << “Congratulations!” << endl; cout << “Congratulations!” << endl;