class Safe:
    def __init__(self, password):
        self.password = password
    def open(self,pw):
        if pw == self.password:
            print("열였습니다")
        else:
            print("비밀번호가 다릅니다")

safe = Safe("1234")
safe.open("0000")
safe.open("1234")

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: