We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b0227a8 commit f90d5acCopy full SHA for f90d5ac
271A - Beautiful Year.cpp
@@ -0,0 +1,28 @@
1
+// ॐ नमः शिवाय
2
+#include<bits/stdc++.h>
3
+using namespace std;
4
+#define pb push_back
5
+
6
+// Code Written By: Vikash Patel
7
+// Codeforces Profile: https://codeforces.com/profile/vikashpatel
8
9
+int main()
10
+{
11
+ int y;
12
+ cin>>y;
13
+ int n=y+1;
14
+ while(true)
15
+ {
16
+ string s = to_string(n);
17
+ set<int> st;
18
+ for(auto i:s)
19
20
+ st.insert(i-'0');
21
+ }
22
+ if(st.size()==4)
23
+ break;
24
+ n++;
25
26
+ cout<<n<<endl;
27
+ return 0;
28
+}
0 commit comments