title: ArrayList error - Cannot find symbol
body: <p>I'm working on a final project for school and having some troubles. I have never done any programming in Java or really anything Object Oriented, so my code's likely not going to be that great.</p>
  
  <p>I'm having some issues with my array list. I am getting an error that says cannot find symbol - class studentInfo. What am I doing incorrectly with my code? This is preventing me from compiling the code. All student info is fake. </p>
  
  <p>Also would anyone have any recommendations on how to clean up or optimize my code?</p>
  
  <pre><code>import java.util.ArrayList;
  import java.util.regex.Matcher;
  import java.util.regex.Pattern;
  
  public class Roster
  {
     private static ArrayList&lt;studentInfo&gt; studentList = new ArrayList&lt;&gt;();
  
     public static void main(String[] args)
      {
  
          add(1, "John", "Smith", "John1989@gmail.com", 20, 88, 79, 59);
          add(2, "Suzan", "Erickson", "Erickson_1990@gmailcom", 19, 91, 72, 85);
          add(3, "Jack", "Napoli", "The_lawyer99yahoo.com", 19, 85, 84, 87);
          add(4, "Erin", "Black", "Erin.black@comcast.net", 22, 91, 98, 82);
          print_all();
          print_invalid_emails();
          print_average_grade(2);
          remove(3);
          remove(3);
  
  
  
      }
     public static void add (int studentID, String firstName, String lastName, String email, int age, int grade1, int grade2, int grade3)
     {
         int[] grades = {grade1, grade2, grade3};
         studentInfo newStudent = new studentInfo (studentID, firstName, lastName, email, age, grades);
         studentList.add(newStudent);
     }
  
    public static void remove(int studentID) 
    {
        for (studentInfo i: studentList) {
            if (i.getStudentID == studentID) {
                studentList.remove(i);
                System.out.println("Student Removed");
              } 
            else {
              System.out.println("A student with this ID(studentID) was not found.");
              return;
              }  
  
          }
    }
    public static void print_all (){
      for (studentInfo i: studentList) {
          studentList.get(i).print();
      }
    }
    public static void print_average_grade(int studentID) {
        studentList.get(studentID).getAverageGrade();
   }
  
   public static void print_invalid_emails() {
       String RFC5322 = "^[a-zA-Z0-9_!#$%&amp;'*+/=?`{|}~^.-]+@[a-zA-Z0-9.-]+$";
       Pattern pattern = Pattern.compile(RFC5322);
       for (studentInfo i: studentList) {
           String email = i.getEmail;
           Matcher matcher = pattern.matcher(email);
           System.out.println(email +":\t"+ matcher.matches());
       }
  
   }
  
  
  }
  </code></pre>
  
  <p>My second class</p>
  
  <pre><code>public class Student
  {
      private int studentID;
      private String firstName;
      private String lastName;
      private String email;
      private int age;
      private int[] grades;
  
      public Student (int studentID, String firstName, String lastName, String email, int age, int grades[]) 
      {
      setStudentID(studentID);
      setFirstName(firstName);
      setLastName(lastName);
      setEmail(email);
      setAge(age);
      setGrades(grades);
  
      }
  
      public void setStudentID(int studentID) {
          this.studentID = studentID;
      }
  
      public void setFirstName(String firstName) 
      {
          this.firstName = firstName;
      }
  
      public void setLastName(String lastName) {
          this.lastName = lastName;
      }
  
      public void setEmail(String email) {
          this.email = email;
      }
  
      public void setAge(int age) {
          this.age = age;
      }
  
      public void setGrades(int[] grades) {
          this.grades = grades;
      }
  
      public int getStudentID() {
         return studentID;
      }
  
      public String getFirstName() {
         return firstName;
      }
  
      public String getLastName() {
          return lastName;
      }
  
      public String getFullName() {
          return firstName + lastName;
      }
  
      public String getEmail() {
          return email;
      }
  
      public int getAge() {
          return age;
      }
  
      public int[] getGrades() {
          return grades;
      }
  
      public int getAverageGrade() {
          int averageGrade = 0;
              for (int grade : grades) {
                  averageGrade += grade;
              }
          return averageGrade;
      }
      public void print() {
          System.out.println(
          "Student Name:\t" + getFullName() + "\n " + 
          "Student ID:\t" + getStudentID() + "\n" + 
          "Email:\t" + getEmail() + "\n" + 
          "Age:\t" + getAge() + "\n" +
          "Average Grade:\t" + getAverageGrade()
          );
  
      }
  
  
  }
  </code></pre>