Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <cstdio>
- #include <iostream>
- #include <cstdlib>
- using namespace std;
- int main()
- {
- int a=0,b=0,k=1,maxi;
- do
- {
- cout<<"Podaj a:"<<endl;
- cin>>a;
- if(a==b)
- {
- k++;
- b=a;
- }
- if(a!=b)
- {
- k=1;
- b=a;
- }
- }
- while(k<3);
- cout<<"elko"<<endl;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement