类的定义分为两部分:
类声明和类体
class people
people就是类名
类体
Lader :声明了 4个float类型变量 above bottom height area ;
方法定义部分用了两个方法 float computerArea ( ) 和void setheight(float h).
在这里插入图片描述
类的定义分为两部分:
类声明和类体
class people
people就是类名
类体
Lader :声明了 4个float类型变量 above bottom height area ;
方法定义部分用了两个方法 float computerArea ( ) 和void setheight(float h).
在这里插入图片描述