From 40de87995b901f72a4dd1f394af3c20c24c73541 Mon Sep 17 00:00:00 2001 From: Kyle K Date: Sun, 13 Sep 2020 16:49:33 -0500 Subject: small class exmaple with a global variable --- foo.py | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 foo.py (limited to 'foo.py') diff --git a/foo.py b/foo.py new file mode 100644 index 0000000..823d1f7 --- /dev/null +++ b/foo.py @@ -0,0 +1,10 @@ +class Foo: + pass +def hello(): + print('hello, world') +x = 13 + +class Square(): + def __init__(self, x): + self.inital = x + self.squared = x**2 -- cgit v1.2.3