The last item · รายการสุดท้าย
This page needs a recent browser (with SharedArrayBuffer support). Please update Chrome, Edge, Firefox or Safari to the latest version. · หน้านี้ต้องใช้เบราว์เซอร์ล่าสุด (รองรับ SharedArrayBuffer) กรุณาอัปเดต Chrome, Edge, Firefox หรือ Safari เป็นเวอร์ชันล่าสุด
This one builds on a lesson you haven't finished yet. Do that lesson first: · อันนี้สร้างจากบทเรียนที่คุณยังไม่เสร็จสิ้น ให้ทำบทเรียนนั้นก่อน:
Python Basics · Functions →
English
The last item
A list keeps items in order. xs[-1] is the last one.
ไทย
รายการสุดท้าย
ลิสต์เก็บรายการตามลำดับ. xs[-1] คือรายการที่ สุดท้าย
Complete last(xs): return the last item of the list xs. Hint: xs[-1]. · เติม last(xs): กลับค่า last รายการของ list xs ทริค: xs[-1]
Click Run to see the output here. · คลิก Run เพื่อดูผลลัพธ์ที่นี่