Change to the directory you created last week. For instance:
1) DUE AT THE END OF LAB
a) Copy the FootballPartyFood.cpp file to your directory via the following command:
c) Compile and run. Note that it does not work properly.
d) Modify the program so that it works as described. RESTRICTION: You are only allowed to modify function headers.
e) Add any comments you feel are appropriate.
Handin as follows:
handin cmsc162 lab1football FootballPartyFood.cpp
2) For this, you will create a program from scratch. Create a file called XObox.cpp that, when the main program is run, it will:
- ask the user for two numbers, a width and a height
- take those two numbers and displays a box of O's of that width and height, with X's around the outside. For instance, width = 5 and height = 4 should produce:
The box should be displayed in the console/terminal
handin cmsc162 lab1xo yourprogramfilename.cpp
3) Get the directory StringReview:
cp -r ~scottmce/162files/StringReview .
Note that the -r says to get the contents of this whole directory. ("r" stands for recursive, which we will be discussing in a couple of weeks.)
Now, change into the directory: cd StringReview
Look at all of the code in the directory
Look at all of the code in this directory. Understand the nature of the prototypes as well as the .h vs .cpp file structure.
Your task is to complete the three functions in StringFuncs.cpp
For purposes of this assignment in addition to AEIOU, Y is considered to be a vowel unless it is followed by another vowel.
To compile your program:
compile TestingStringFuncs.cpp StringFuncs.cpp
compile *.cpp which uses the "wildcard" *
You will likely wish to modify the testing file to include additional test cases. I certainly will be adding addiitonal test cases when I grade.
Handin as follows:
handin cmsc162 lab1strings StringFuncs.cpp