Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <cstdlib>
- #include <iostream>
- using namespace std;
- class osoba
- {
- private:
- string imie;
- string nazwisko;
- string pesel;
- public:
- void wprowadz();
- void wyswietl();
- };
- int main(int argc, char *argv[])
- {
- osoba os1;
- os1.wprowadz();
- os1.wyswietl();
- system("PAUSE");
- return EXIT_SUCCESS;
- }
- void osoba::wprowadz()
- {
- cout << "Wprowadz dane" << endl;
- cin >> imie >> nazwisko >> pesel;
- }
- void osoba::wyswietl()
- {
- cout << "Dane:" << endl;
- cout << imie << " "<< nazwisko <<" "<< pesel<<endl;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement