```
a_dictionary = {"a" : 1, "b" : 2}
file = open("sample.txt", "w")
str_dictionary = repr(a_dictionary)
#"\n" creates newline for next write to file
file.write("a_dictionary = " + str_dictionary + "\n")
file.close()
```
參考來源: https://www.kite.com/python/answers/how-to-write-a-variable-to-a-file-in-python
Python
SQL Server Analytics Service 1
SEO(1) Github(2) Title Tag(2) ML(1) 李宏毅(1) SQL Server(18) Tempdb(1) SSMS(1) Windows(1) 自我成長(2) Excel(1) python Flask(1) python(5) Flask(2)
Max Chen (159)