Capitalize

Project #1

Create an interactive program that:

  1. ask the user for the name of a (small) text file
  2. reads the text file
  3. print each line with every word capitalized
  4. loop

Question: Are there string methods that can help?

Project #2

The same as project #1 except capitalize the first word in each sentence.

Note:
a. Make sure you are testing with a text file that has (at least some) un-capitalized sentences.
a. Also, sentences can span multiple lines or a line may contain multiple sentences.
c. What to do with hyphenated words? Other special cases?

Project #3

Capitalize each word except for the first letter which is lowercase.

Need some test file? Click HERE .