id = $id; $this->name = $name; $this->city = $city; $this->salary = $salary; } } $employees = [ new Employee(1, "Dór Tamás", "Szeged", 2875000), new Employee(2, "Ber Ferenc", "Szolnok", 2375000) ]; print_r($employees);