正在加载图片...
Summary Object-oriented programming is another way(paradigm)to organize and reason about programs The Python class statement allows us to create user-defined data types that can be used just like built-in data types o Class attributes are variables shared across instances o Instance attributes are unique to each instance o Two ways to invoke methods,implicitly and explicitly. o Tomorrow,we'll discover how to define the relationships between different classes In lab,you'll use OOP to make a trading card game!Summary ● Object-oriented programming is another way (paradigm) to organize and reason about programs ● The Python class statement allows us to create user-defined data types that can be used just like built-in data types ○ Class attributes are variables shared across instances ○ Instance attributes are unique to each instance ○ Two ways to invoke methods, implicitly and explicitly. ○ Tomorrow, we'll discover how to define the relationships between different classes ● In lab, you’ll use OOP to make a trading card game!
<<向上翻页
©2008-现在 cucdc.com 高等教育资讯网 版权所有