Docsity

Quiz 3 - Object Oriented Programming I - Spring 2005 | CMSC 131, Quizzes of Computer Science

Toggle sidebar
bg1
1
CMSC131 Spring 2005 Quiz #3, Duration 25 Minutes
First Name:
Last Name:
Class account LOGIN ID:
Section: TAs:
Write pseudocode for a program that computes the sum of the even numbers from user-provided
values. The program will first read the number of values (N) that the user will input. It will then
process the N values from user input, one by one. Finally, it will print the sum.
To keep things simple, you can read in the next integer and store it in some variable x as follows:
x = read()
You can print a value x or message as follows:
print(x) or print(“Hello”)
You do not need to implement any Java code for this problem, just the pseudocode.
Remember, pseudocode should be detailed enough that it can be converted by a
competent programmer into Java, but should not contain Java-specific details.
pf2

Partial preview of the text

Download Quiz 3 - Object Oriented Programming I - Spring 2005 | CMSC 131 and more Quizzes Computer Science in PDF only on Docsity!

CMSC131 Spring 2005 Quiz #3, Duration 25 Minutes

First Name: Last Name: Class account LOGIN ID: Section: TAs:

Write pseudocode for a program that computes the sum of the even numbers from user-provided values. The program will first read the number of values (N) that the user will input. It will then process the N values from user input, one by one. Finally, it will print the sum.

To keep things simple, you can read in the next integer and store it in some variable x as follows:

x = read()

You can print a value x or message as follows:

print(x) or print(“Hello”)

You do not need to implement any Java code for this problem, just the pseudocode.

Remember, pseudocode should be detailed enough that it can be converted by a

competent programmer into Java, but should not contain Java-specific details.

WRITE YOUR PSEUDOCODE ON THIS PAGE.