Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<iostream>
- #include<climits>
- using namespace std;
- int main()
- {
- int n, i, x, minim=INT_MAX;
- cin>>n;
- for(i=1; i<=n; i++)
- {
- cin>>x;
- if(x/100%10==x/10%10 && x<minim )
- {
- minim=x;
- }
- }
- cout<<minim;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment