2025年3月4日上課Python 陣列array串列的函數(方法)

animal = ["豬", "牛", "羊", '貓'] #python語言的註解comments x = animal.copy() print(animal) x.reverse() #將x反轉reverse print(x) animal.append('狗') print(animal) y = animal.copy() y.reverse() #將x反轉reverse print(y)

留言

  1. 期中考https://takming123.blogspot.com/2025/04/oopobject-oriented-programming.html
    https://takming123.blogspot.com/2025/03/202534python-array.html

    回覆刪除

張貼留言

這個網誌中的熱門文章

蔡欣辰SPYDER PYTHON二分法

蔡欣辰HTML按鈕BUTTON事件ONCLICK