From 60bf85e4211bee24cb76bcd2f66eafe547f30927 Mon Sep 17 00:00:00 2001 From: Zeheng Li Date: Tue, 15 Oct 2024 16:41:18 -0600 Subject: [PATCH] add example --- src/babylonian.py | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 src/babylonian.py diff --git a/src/babylonian.py b/src/babylonian.py new file mode 100644 index 0000000..2c094e7 --- /dev/null +++ b/src/babylonian.py @@ -0,0 +1,4 @@ +n = int(input()) +for _ in range(n): + d = [int(v or 0) for v in input().split(",")] + print(sum(v * (60**i) for i, v in enumerate(d[::-1])))