ZhangZhihui's Blog  
上一页 1 ··· 60 61 62 63 64 65 66 67 68 ··· 116 下一页

2024年7月30日

摘要: The print function can also be used to write to a file. The output of print, that is by default, sent to the screen can be redirected to an open file. 阅读全文
posted @ 2024-07-30 15:12 ZhangZhihuiAAA 阅读(33) 评论(0) 推荐(0)
 
摘要: 'r' - read mode(default) 'w' - write mode 'a' - append mode 'x' - exclusive creation We know that the mode 'r' opens an existing file for reading only 阅读全文
posted @ 2024-07-30 14:45 ZhangZhihuiAAA 阅读(54) 评论(0) 推荐(0)
 
摘要: Each module is loaded into memory only once during an interpreter session or during a program run, regardless of the number of times it is imported in 阅读全文
posted @ 2024-07-30 11:37 ZhangZhihuiAAA 阅读(40) 评论(0) 推荐(0)
 
摘要: def func(s:str, i:int, j:int) -> str: return s[i:j] The parameter s is supposed to be a string, so we place a colon after the parameter name and then 阅读全文
posted @ 2024-07-30 11:17 ZhangZhihuiAAA 阅读(23) 评论(0) 推荐(0)
 
摘要: Parameters in Function Definition A. def func(name): Match by position or by name B. def func(name=value): Default argument C. def func(*args): Collec 阅读全文
posted @ 2024-07-30 11:06 ZhangZhihuiAAA 阅读(29) 评论(0) 推荐(0)

2024年7月29日

摘要: Unlike some other languages, in Python, the logical operators "and" and "or" do not return Boolean values True or False; they actually return the last 阅读全文
posted @ 2024-07-29 21:06 ZhangZhihuiAAA 阅读(41) 评论(0) 推荐(0)
 
摘要: To select a random item from the list or shuffle the list, you can use the choice and shuffle functions from the random module of the standard library 阅读全文
posted @ 2024-07-29 20:05 ZhangZhihuiAAA 阅读(36) 评论(0) 推荐(0)

2024年7月2日

摘要: 阅读全文
posted @ 2024-07-02 11:40 ZhangZhihuiAAA 阅读(15) 评论(0) 推荐(0)

2024年6月26日

摘要: zzh@ZZHPC:/zdata/Github/mastering-go-expertise/stats_web/server$ go run . Ready to serve at :1234 zzh@ZZHPC:~$ curl localhost:1234/list d6 4 2.325000 阅读全文
posted @ 2024-06-26 17:41 ZhangZhihuiAAA 阅读(210) 评论(0) 推荐(0)

2024年6月25日

摘要: services: stats_server: image: stats_server container_name: stats_server restart: always ports: - 1234:1234 networks: - stats networks: stats: driver: 阅读全文
posted @ 2024-06-25 22:24 ZhangZhihuiAAA 阅读(19) 评论(0) 推荐(0)
上一页 1 ··· 60 61 62 63 64 65 66 67 68 ··· 116 下一页