class Box:
def __init__(self, date="", contents="", location=""):
self.d = date
self.c = contents
self.l = location
def displayBox(self):
if self.d != "":
print("The date is " + self.d)
else:
print("The date was not supplied")
if self.c != "":
print("The contents are " + self.c)
else:
print("The contents were not supplied")
if self.l != "":
print("The location is " + self.l)
else:
print("The location was not supplied")
obj = Box("2016", "medical records")
obj.displayBox()
This is how you would create a class in python. Your code seems to be part python part some other language. I hope this helps!