class Person{ int age; String name; public Person(int age,String name){ this.age=age; this.name=name; } public void showInfo(){ System.out.println("那个人的名字是"+this.name); }}public class Blue { /** * @param args */ public static void main(String[] args) { // TODO Auto-generated method stub Person p1=new Person(23,"郭德纲"); p1.showInfo(); }}
添加回答
举报
0/150
提交
取消