> Student *sa[3];
If you want an array, just type Student sa[3] and leave out the *
I believe that's actually a pointer to an array of Students.
And then you can use this:
sa[0] = Student("James");
sa[1] = Student("Jason");
If you wanted an array on the heap, you need to declare a pointer to a Student and allocate with new[]
Student *sa;
sa = new Student[3];
and now you can use array indices like in the first example.