Class

  • + 0 comments

    include

    include

    include

    include

    include

    include

    using namespace std;

    class info{ public:
    int age; char first_name[50]; char last_name[50]; int standard;

    void print(int n,int standard,const char* first_name,const char* last_name){ cout<

      cout<<n<<","<<first_name<<","<<last_name<<","<<standard;
    

    }

    }; int main() {

    info obj1;
    
    int n;
    char first_name[50];
    char last_name[50];
    int standard;
    
    cin>>n;
    cin>>first_name;
    cin>>last_name;
    cin>>standard;
    
    obj1.print(n,standard,first_name,last_name);
    
    return 0;
    

    }