比較 datetime
想像你正在回顧 2008 年次級房貸風暴的關鍵事件。你手上有幾個重要日期的 datetime,包含雷曼兄弟宣告破產、TARP 法案通過,以及高盛與摩根士丹利退出投資銀行業務。
本練習屬於課程
Intermediate Python for Finance
動手互動練習
試著完成這個範例程式碼,體驗一下這個練習。
# Lehman Brothers before Morgan Stanley?
lehman_first = lehman ____ morgan_stanley
print(f"It is {lehman_first} that Lehman Brothers declared bankruptcy first.")