[Home | Assignments | Links | Grades | CIS 313]

CIS 323 - Winter Warmup

Hello World!


Due Thursday, January 14, 2010

You must write your code in C++ for this assignment.

Write a hello world program that uses standard input and output, compile and run it using the GNU toolkit on IX. The input you will be given will be formatted as an integer on its own line (representing the number of people to greet) and then every name on its own line, in order. Your program will read each name, such as "David", from standard input and print a greeting to standard output for each name: "Hello, David!"

Here is an example:

Input:
7
Bashful
Doc
Dopey
Grumpy
Happy
Sleepy
Sneezy
Output:
Hello, Bashful!
Hello, Doc!
Hello, Dopey!
Hello, Grumpy!
Hello, Happy!
Hello, Sleepy!
Hello, Sneezy!

You should conform exactly to the input and output specification, as I will be using automated scripts to check your results. So let me say it again: conform exactly to the input and output specification! This assignment is meant to prepare you for using standard input and output according to my specifications because all other assignments will follow a similar template. I cannot stress enough how important it is to get used to this as soon as possible.

Submission

No further submission possible.
Last updated: January 18, 2010 | David Lebech