CSc 250: Printouts

In this assignment, you will write multiple very simple python programs that print out static text. There are a few tricky parts that you’ll need to use escape-sequences for, but overall it shouldn’t be too hard!

The Road not taken

Write a python program that prints the first part of “The road not taken” poem by Robert Frost:

Two roads diverged in a yellow wood,
And sorry I could not travel both
And be one traveler, long I stood
And looked down one as far as I could
To where it bent in the undergrowth;

Call this road.py.

Star Wars

Write a python program that when run, prints out exactly the below text to the console.

*** A large, multiple-eyed Creature gives Luke a rough shove.  ***

CREATURE: "Negola dewaghi wooldugger?!?"

*** The hideous freak is obviously drunk. Luke tries to ignore ***
*** the creature and turns back on his drink. A short, grubby  ***
*** Human and an even smaller rodent-like beast join the       ***
*** belligerent monstrosity.                                   ***

HUMAN: "He doesn't like you."

LUKE: "I'm sorry."

HUMAN: "I don't like you either."

*** The big creature is getting agitated and yells out some    ***
*** unintelligible gibberish at the now rather nervous, young  ***
*** adventurer.                                                ***

HUMAN: "Don't insult us.
        You just watch yourself. 
        We're wanted men.
        I have the death sentence in twelve systems."

LUKE: "I'll be careful then."

HUMAN: "You'll be dead!"

Name this program starwars.py.

Fancy Poem

Write a python program that when run, prints out exactly the below text to the console. This is the same poem as earlier, but with extra “decoration” text.

""" ''' """ ''' """ ''' """ ''' """ ''' """ ''' """
\n\n  Two roads diverged in a yellow wood,   n/n/
\t\t  And sorry I could not travel both      t/t/
\\\\  And be one traveler, long I stood      ////
\/\/  And looked down one as far as I could  \/\/
/\/\  To where it bent in the undergrowth;   /\/\
''' """ ''' """ ''' """ ''' """ ''' """ ''' """ '''

Call it fancy.py.

Comments

All of your programs should be well-formatted and easy for the graders to read and comprehend. You should follow the style guidelines that we have discussed in class. Each program file should have a header comment at the top that has roughly the following format:

#
# Author: Student Name
# Description:
#    A short description of what this program does!
# 

Submission and grading

This was assigned on January 12th, 2018. It is due on January 19th at 5:00pm.

Turn in each of the files described in the spec (3) to the assignment drop-box in D2L before the due date. Make sure to name the files exactly as this document specifies. In general, make sure to follow these instructions precisely. If you don’t, we will deduct points!!!