public class _01Celebrity{//属性public String name;public int age;public double height;public char gender;//构造器public _01Celebrity(String name,int age,double height,char gender){this.name = name;this.age = age;this.height = height;this.gender = gender;}//方法void sing(String sing) {System.out.println(this.name+" 唱: "+sing);}void dance(String dance) {System.out.println(this.name+" 跳: "+dance); }void showUserInfo() {System.out.println("明星信息:姓名: "+this.name); System.out.println("年龄: "+this.age); System.out.println("身高: "+this.height); System.out.println("性别: "+this.gender); }public static void main(String[] args) {_01Celebrity zly = new _01Celebrity("赵丽颖",18,165,'女');_01Celebrity fengjie = new _01Celebrity("凤姐",28,168,'女');zly.showUserInfo();zly.sing("想你");zly.dance("流行舞蹈");System.out.println("================================="); fengjie.showUserInfo();fengjie.sing("今天我要嫁给你");fengjie.dance("广场舞");} }