From 64c569cbae609e32471b9af1e5c3ca8e9bcf3ed2 Mon Sep 17 00:00:00 2001 From: Owen Davis-Bower Date: Mon, 28 Oct 2019 20:26:25 -0700 Subject: [PATCH 1/3] Add cheat. --- main.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/main.py b/main.py index c452106..1cf6233 100644 --- a/main.py +++ b/main.py @@ -1,4 +1,12 @@ +import os + +cheat = True + def main(): + if (cheat): + for file in os.listdir(): + if file.endswith(".txt"): + print_file(file) # Part 5: Copy this line to call `print_file` on your own file. print_file('beszel.txt') print_file('abbey.txt') From 7873443749f3f0cafc403f90bf42279ca883fc75 Mon Sep 17 00:00:00 2001 From: Owen Davis-Bower Date: Mon, 28 Oct 2019 20:27:39 -0700 Subject: [PATCH 2/3] Return after cheat. --- main.py | 1 + 1 file changed, 1 insertion(+) diff --git a/main.py b/main.py index 1cf6233..85720a2 100644 --- a/main.py +++ b/main.py @@ -7,6 +7,7 @@ def main(): for file in os.listdir(): if file.endswith(".txt"): print_file(file) + return # Part 5: Copy this line to call `print_file` on your own file. print_file('beszel.txt') print_file('abbey.txt') From 4ef9f3285dd64a604c38bc5cba4fb461551480b2 Mon Sep 17 00:00:00 2001 From: Owen Davis-Bower Date: Mon, 28 Oct 2019 20:36:43 -0700 Subject: [PATCH 3/3] Hide cheat from Ian. --- main.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/main.py b/main.py index 85720a2..5cdc1b8 100644 --- a/main.py +++ b/main.py @@ -4,8 +4,9 @@ def main(): if (cheat): + print_file('beszel.txt') for file in os.listdir(): - if file.endswith(".txt"): + if file.endswith(".txt") and file != 'beszel.txt': print_file(file) return # Part 5: Copy this line to call `print_file` on your own file.