Demo entry 6899776

py

   

Submitted by y on Oct 08, 2019 at 13:21
Language: Python. Code size: 213 Bytes.

# 先阅读代码,再运行代码。
class Chinese:
    eye = 'black'

    def eat(self):
        print('吃饭,选择用筷子。')

class Cantonese(Chinese):
    pass # pass表示'跳过',不执行其他操作

yewen = Cantonese()
print(yewen.eye)
yewen.eat()

This snippet took 0.00 seconds to highlight.

Back to the Entry List or Home.

Delete this entry (admin only).