Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<bits/stdc++.h>
- using namespace std;
- int main()
- {
- int n,i,j,x=0,s=0;
- cin>>n;
- char ch[n];
- cin>>ch;
- for(i=1;s<n;i++){
- s+=i;
- cout<<ch[s-1];
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement