陳昕妤LIST清單DICT字典RANDOM模組

#註解陳昕妤學過python
import random
x=[i for i in range(10)]
print('產生清單',x)
y={}
for i in x:
   y[i]=random.random()
print(y) 
for i in y:
   print(i,y[i])
   

留言

  1. 620有執行嗎?https://cynthiachen59.blogspot.com/2025/06/blog-post.html
    https://cynthiachen59.blogspot.com/2025/06/listdictrandom.html

    回覆刪除

張貼留言

這個網誌中的熱門文章

陳昕妤python運算CSV輸出TKINTER投資風險與報酬Markowitz 6月 19, 2025

陳昕妤期中考python讀取csv檔案