You are viewing a single comment's thread. Return to all comments →
you mean like this '#include
using namespace std;
int main() {
string s; getline(cin, s); int length=s.length(); int ul=0,ll=0; for(int i=1; i<=9; i++) { if(i*i>length) { ul=i; ll=i-1; break; } else if(i*i==length) { ul=i; ll=i; break; } } //cout<<ul<<" "<<ll<<endl; int i=0; while(i<ul && i<s.length()) { int j=i; while(j<s.length()) { cout<<s[j]; j=j+ul; //cout<<j; } cout<<" "; i=i+1; } return 0;
}
Seems like cookies are disabled on this browser, please enable them to open this website
Encryption
You are viewing a single comment's thread. Return to all comments →
you mean like this '#include
using namespace std;
int main() {
}