Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- class ksiazki
- {
- int ilosc_ksiazek;
- public:
- void wypozyczenie(int a);
- };
- void ksiazki::wypozyczenie(int a)
- {
- if(a>3) cout<<"Nie mozesz wypozyczyc wiecej ksiazek."<<endl;
- else cout<<"Mozesz jeszcze wypozyczyc ksiazki."<<endl;
- }
- int main()
- {
- int x;
- cout<<"Ilosc wypozyczonych ksiazek: "<<endl;
- cin>>x;
- ksiazki nowy;
- nowy.wypozyczenie(x);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement