和老师一样为什么会报错呢?求同学指出一下感谢感谢
import java.util.HashSet;
import java.util.Set;
/**
* 学生类
* @author Administrator
*
*/
public class Student {
public String id;
public String name;
public Set<Course> courses;
public Student(String id, String name) {
this.id = id;
this.name = name;
this.courses = new HashSet<Course>();
}
}
你的把鼠标移到那个x的地方看看报的错误是什么啊,
或者你可以复制一下我的代码看会不会出错;
package com.imooc.collection;
import java.util.HashSet;
import java.util.Set;
/**
* 学生类
* @author Administrator
*
*/
public class Student {
public String id;
public String name;
public Se courses;
public Student(String id, String name) {
this.id = id;
this.name = name;
this.courses = new HashSet();
}
}