From 90d722def0ea257c65eeb030905a59cb9b30dc9f Mon Sep 17 00:00:00 2001 From: Paul Maier Date: Fri, 10 Dec 2021 12:50:31 +0100 Subject: [PATCH] try it out --- Day01/day01.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/Day01/day01.py b/Day01/day01.py index e981639..40a2a23 100644 --- a/Day01/day01.py +++ b/Day01/day01.py @@ -17,9 +17,16 @@ def day01Part1(): print('Part1: Number of increases: ', counter) def day01Part2(): - print('hello') - + with open("data/input.txt","r") as f: + myInput=f.read().splitlines() + counter=0 + previous=int(myInput[0]) + for item in myInput[1:]: + if int(item) == int(previous): + print('no change') +# if the item before is the same as the one after than it will say no change if __name__=='__main__': day01Part1() day01Part2() +