summaryrefslogtreecommitdiff
path: root/progs/a334.py
diff options
context:
space:
mode:
Diffstat (limited to 'progs/a334.py')
-rw-r--r--progs/a334.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/progs/a334.py b/progs/a334.py
new file mode 100644
index 0000000..b481a67
--- /dev/null
+++ b/progs/a334.py
@@ -0,0 +1,4 @@
+def series_sum(number):
+ total = 0
+ total = (number * (number + 1) * (2 * number + 1)) / 6
+ return total \ No newline at end of file