Department of Engineering

IT Services

Some of the exercises below can be answered in a dozen or so lines of code using the Standard Library, but you'll need to explore the documentation first.

1.
Write a program that given a string by the user determines whether it reads the same both ways
2.
Each line in the unix password file (/etc/passwd) begins with a uid (up to the first ':'). Write a program that reads the uids into a vector of strings, sorts them and then prints out those beginning with 'q'.
3.
Write a program that you can play tic-tac-toe (noughts and crosses) with.