5 Howler: Working with files and STDOUT
In the Harry Potter stories, a “Howler” is a nasty-gram that arrives by owl at Hogwarts. It will tear itself open, shout a blistering message at the recipient, and then combust. In this exercise, we’re going to write a program that will transform text into a rather mild-mannered version of a Howler by MAKING ALL THE LETTERS UPPERCASE. The text that we’ll process will be given as a single positional argument. |
For instance, if our program is given the input, “How dare you steal that car!” it should scream back “HOW DARE YOU STEAL THAT CAR!” Remember spaces on the command line delimit arguments, so ...
Get Tiny Python Projects now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.