Browse Source

Create 8 kyu - Quarter of the Year.py

PythonCoder8 3 years ago
parent
commit
a8c85d52d5
1 changed files with 9 additions and 0 deletions
  1. 9 0
      8 kyu/8 kyu - Quarter of the Year.py

+ 9 - 0
8 kyu/8 kyu - Quarter of the Year.py

@@ -0,0 +1,9 @@
+def quarter_of(month):
+    if month in (1,2,3):
+        return 1
+    if month in (4,5,6):
+        return 2
+    if month in (7,8,9):
+        return 3
+    if month in (10,11,12):
+        return 4