From b56e9198031fa3bde98e608837856cf2e00cb18c Mon Sep 17 00:00:00 2001 From: Abigail Date: Wed, 20 Jan 2021 12:42:08 +0100 Subject: Python solution for week 1/part 1 --- challenge-001/abigail/python/ch-1.py | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 challenge-001/abigail/python/ch-1.py (limited to 'challenge-001/abigail/python/ch-1.py') diff --git a/challenge-001/abigail/python/ch-1.py b/challenge-001/abigail/python/ch-1.py new file mode 100644 index 0000000000..193586bcf6 --- /dev/null +++ b/challenge-001/abigail/python/ch-1.py @@ -0,0 +1,11 @@ +# +# See ../READE,md +# + +# +# Run as python ch-1.py < input-file +# +import fileinput + +for line in fileinput . input (): + print line . replace ("e", "E"), line . count ("e") -- cgit