From a0775260db45da10dd37d267d3f7eeccfe9252e2 Mon Sep 17 00:00:00 2001 From: daviddoji Date: Mon, 3 Oct 2022 15:59:23 +0200 Subject: [PATCH] Adopted new convention from template --- src/Python/Problem059.py | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/Python/Problem059.py b/src/Python/Problem059.py index ec58bbb..cdb8c8b 100644 --- a/src/Python/Problem059.py +++ b/src/Python/Problem059.py @@ -1,4 +1,4 @@ -#!/usr/bin/env python3 +#!/usr/bin/env python """ Created on 13 Oct 2021 @@ -11,6 +11,7 @@ https://projecteuler.net/problem=59 from itertools import permutations from string import ascii_lowercase + from utils import timeit @@ -46,10 +47,8 @@ def compute(): """ with open("../files/Problem59.txt", "r") as f: - # encrypted = list(map(int, f.read().split(','))) encrypted = [int(char) for char in f.read().split(",")] - # print(encrypted) - # print(test) + plain_text = len(encrypted) // 3 for key in permutations(ascii_lowercase, 3): decrypted = "" @@ -62,5 +61,4 @@ def compute(): if __name__ == "__main__": - - print(f"Result for Problem 59: {compute()}") + print(f"Result for Problem 59 is {compute()}")