moved import to top of class

This commit is contained in:
Mark McIntyre 2022-06-28 18:03:50 -04:00
parent 10c73653cf
commit 5cd80e5354

View File

@ -1,5 +1,7 @@
class Calculator():
from math import log
def __init__(self):
self.total = 0.0
self.actions = []
@ -75,8 +77,6 @@ class Calculator():
self.actions.append(f" = {self.total}")
def log(self, val):
from math import log
print(log(val))
self.actions.append(f"log({val})")