Skip to content

Instantly share code, notes, and snippets.

@KKarthikeya
Created August 16, 2015 04:24
Show Gist options
  • Save KKarthikeya/47adee1a14deaab5adc5 to your computer and use it in GitHub Desktop.
Save KKarthikeya/47adee1a14deaab5adc5 to your computer and use it in GitHub Desktop.
1 Write a program that prompts for a file name, then opens that file and reads through the file, and print the contents of the file in upper case. Use the file words.txt to produce the output below. You can download the sample data at http://www.pythonlearn.com/code/words.txt
for data in open(raw_input("Enter file name: ")):
print data.rstrip().upper()
@sspatil999
Copy link

for data in open(raw_input("Enter file name: ")):
print data.rstrip().upper()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment