class schmwong(github.user):
name = "Paul"
country = "Singapore 🇸🇬"
spoken_languages = {
working: "English",
second_working: "Mandarin Chinese",
national: "Malay",
colloquial: "Singlish"
}
personality = "INTP"
interests = [
"🔐 Cyber Security",
"🤖 Process Automation in the Cloud",
"💈 Data Pipelines"
]
def __init__(self, birth_year=1582):
super(schmwong, self).__init__(userinfo)
self.age = datetime.now().year - int(birth_year) # ♑
account.type = "Personal"
def thank_decorator(func):
def wrapper():
func()
print("Thanks for dropping by")
return wrapper
@thank_decorator
def hello(name=schmwong.name, country=schmwong.country):
print(f"Hi, {name} here 👋")
print(f"I'm from {country}")
類別 schmwong(github.使用者):
名 = "Paul"
國籍 = "新加坡 🇸🇬"
語言能力 = {
工作語言: "英式英語",
第二工作語言: "華語",
國語: "馬來語",
口語: "星式英語"
}
人格 = "INTP"
興趣 = [
"🔐 網路安全",
"🤖 雲端流程自動化",
"💈 數據管道"
]
定義 __初始__(俺, 出生年=1582):
超級(schmwong, 俺).__初始__(使用者資訊)
俺.年齡 = datetime.now().year - 整數(出生年) #♑
帳號.類型 = "個人"
定義 歡迎_裝飾器(函數):
定義 包裝器():
函數()
印("歡迎參觀我的個人頁面")
傳回 包裝器
@歡迎_裝飾器
定義 問候(名=schmwong.名, 國籍=schmwong.國籍):
印("你好, 我是, ", 名, " 👋")
印("我來自 ", 國籍)