Name: ____________________________________________________ Alpha: _____________________
Describe help received: _________________________________________________________________
while( cin )
{
int a = 100;
cin >> a;
cout << a << endl;
int b = 200;
cin >> b;
cout << b << endl;
}
Suppose that the user gives the following input:
hello
What will be the output of the program? Why?
[90pts] Write a program that reads in a file like this:
that contains a table of integers in unformatted text. |
The program will write out a file output.html that shows the same table in html, which looks like this
which, when opened in a web browser, will render like this: output.html. |
You may assume that the file is named input.txt, and that the
first line of the file tells you how many rows in the table, the second line
tells you how many columns, and that the subsequent lines contain the the values
to appear in the table. Look at w3 tables intro if you
need a little help with tables in HTML.
With input.txt, the result should look like: output.html. To check if your program creates the correct output.html file, it may be useful to open that file using a web browser (use ctrl-o) and see how it looks.
~/bin/submit -c=IC210 -p=hw12 hw.cpp