From d98f46ce647846b0aa30b2e16a30fd4e152a1bf5 Mon Sep 17 00:00:00 2001 From: Carlos Maiolino Date: Thu, 10 Jul 2025 22:55:07 +0200 Subject: Add new code Signed-off-by: Carlos Maiolino --- mit/assertion.py | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 mit/assertion.py (limited to 'mit/assertion.py') diff --git a/mit/assertion.py b/mit/assertion.py new file mode 100644 index 0000000..a196067 --- /dev/null +++ b/mit/assertion.py @@ -0,0 +1,9 @@ +#!/usr/bin/python3 + +def avg(grades): + assert not len(grades) == 0, 'no grades data' + return sum(grades) / len(grades) + +def fodeu(): + a = 7 / 0 + return a -- cgit v1.2.3