#include<iostream> using namespace std; int main() { string s; cin>>s; if(s.size()==4) { int a=stoi(s.substr(0,2)); int b=stoi(s.substr(2,2)); if(a<=21)printf("20%02d-%02d",a,b); else printf("19%02d-%02d",a,b); } else { int a=stoi(s.substr(0,4)); int b=stoi(s.substr(4,2)); printf("%04d-%02d",a,b); } return 0; }