ya theirs a million way to do this yet 1 mistake screws everythign up >_< (i'm more of a networking guy!!)
these are my errors
C:\Documents and Settings\Beserk\Desktop\TestEmployeeClass.java:24: cannot find symbol
symbol : variable employee
location: class TestEmployeeClass
for(int k =0;k < employee.length; k++)
^
C:\Documents and Settings\Beserk\Desktop\TestEmployeeClass.java:28: cannot find symbol
symbol : variable employees
location: class TestEmployeeClass
employees[k] = new EmployeeClass();
^
C:\Documents and Settings\Beserk\Desktop\TestEmployeeClass.java:29: cannot find symbol
symbol : variable employees
location: class TestEmployeeClass
employees[k].getdata();
^
C:\Documents and Settings\Beserk\Desktop\TestEmployeeClass.java:30: cannot find symbol
symbol : variable employees
location: class TestEmployeeClass
employees[k].display();
final code
public class TestEmployeeClass
{
public static void main(String[] args)
{
EmployeeClass s1= new EmployeeClass();
s1.display();
EmployeeClass s2= new EmployeeClass("MARY",1111,75000);
s2.display();
EmployeeClass s3 = new EmployeeClass();
s3.getdata();
s3.display();
s1.display();
//array
EmployeeClass[] students= new EmployeeClass[3];
for(int k =0;k < employee.length; k++)
{
System.out.printf("\nWorking on employee : %d\n", (k+1));
// create an instance for each member
employees[k] = new EmployeeClass();
employees[k].getdata();
employees[k].display();
EmployeeClass[] collection = new EmployeeClass[] {new EmployeeClass(),
new EmployeeClass(), new EmployeeClass()};
for(int i = 0; i < collection.length; i ++) {
collection[i].getdata();
}
for(int j = 0; j < collection.length; j++) {
collection[j].display();
}
}
}
}