无法写下 arrayList 的 addStudent 和 removeStudent 方法

Not able to write down the methods for addStudent and removeStudent for an arrayList

我已经创建了我的数组列表来保存学生的详细信息。

private ArrayList<Student> classList;

然后我在构造函数里初始化了

Course(String courseName)
{
 this.courseName = input.next();
 this.classList = new ArrayList<Student>();
}

我需要写下将 addStudents 和 removeStudents 添加到 arrayList 中的两个方法。我觉得很难做到。关于如何处理此问题的任何帮助或提示?

A​​rrayList 已有添加和删除的方法。

学生 theStudent;

添加学生:

classList.add(theStudent);

删除学生:

classList.remove(theStudent);