public void containsText(){
System.out.println("请您输入您所需要查找的课程:");
Scanner console=new Scanner(System.in);
String name=console.next();
Course cr=new Course();
cr.setName(name);
System.out.println("新添加的课程:"+cr.getName());
System.out.println("是否包括您所输入的课程:"+courseToSelect.contains(cr));
}
比较Course类型,equals和hashcode处理了么