#include<iostream>
#include<string>
#include<cctype>
using namespace std;
class Person
{
    protected:
    string name;
    int age;
    public:
    Person(string n, int a): name(n), age(a){}
    virtual void showDetails()
    {
        cout<<"Name: "<<name<<endl;
        cout<<"Age: "<<age<<endl;
    }
    bool isValidName()
    {
        for(char c: name)
        {
            if(!isalpha(c))
            return false;
        }
        return true;
    }
    bool isValideAge()
    {
        return age>=0;
    }
};
class Employee:public Person
{
    private:
    int empID;
    string department;
    public:
    Employee(string n, int a, int id, string dept)
    :Person(n,a), empID(id), department(dept){}
    void showDetails() override
    {
        cout<<"Name: "<<name<<endl;
        cout<<"Age: "<<age<<endl;
        cout<<"Employee ID: "<<empID<<endl;
        cout<<"Department: "<<department<<endl;
    }
    bool isValidEmpID()
    {
        return empID >=0;
    }
};
int main()
{
    string name, dept;
    int age, empID;
    cin>>name>>age;
    cin>>empID>>dept;
    Employee emp(name, age, empID, dept);
    if(!emp.isValidName()||!emp.isValidAge()||!emp.isValidEmpID())
    {
        cout<<"Invalid inout"<<endl;
        return 0;
    }
    Person* p=&emp;
    p->showDetails();
    return 0;
}