//Time 0ms, Memory 280K
#include<iostream> using namespace std; int main() { int n,t; while(cin>>n) { t=18; while(t<n) t*=18; t/=18; if(t*9>=n) cout<<"Stan wins."<<endl; else cout<<"Ollie wins."<<endl; } return 0; }
//Time 0ms, Memory 280K
#include<iostream> using namespace std; int main() { int n,t; while(cin>>n) { t=18; while(t<n) t*=18; t/=18; if(t*9>=n) cout<<"Stan wins."<<endl; else cout<<"Ollie wins."<<endl; } return 0; }