Submission #2802854


Source Code Expand

Copy
#include <bits/stdc++.h>
using namespace std;

string s,ans;

int main(){
  int i,w;
  cin >> s >> w;
  for(i=0;i<s.size();++i){
    if(i%w==0)ans+=s[i];
  }
  cout << ans <<endl;
  return 0;
}

Submission Info

Submission Time
Task B - Acrostic
User m_tsubasa
Language C++14 (GCC 5.4.1)
Score 200
Code Size 208 Byte
Status
Exec Time 1 ms
Memory 256 KB

Test Cases

Set Name Score / Max Score Test Cases
Sample 0 / 0 sampleId.txt, sampleUdon.txt, sampleabc.txt
All 200 / 200 a7.txt, a8.txt, a9.txt, sampleId.txt, sampleUdon.txt, sampleabc.txt, test_0.txt, test_1.txt, test_2.txt, test_3.txt
Case Name Status Exec Time Memory
a7.txt 1 ms 256 KB
a8.txt 1 ms 256 KB
a9.txt 1 ms 256 KB
sampleId.txt 1 ms 256 KB
sampleUdon.txt 1 ms 256 KB
sampleabc.txt 1 ms 256 KB
test_0.txt 1 ms 256 KB
test_1.txt 1 ms 256 KB
test_2.txt 1 ms 256 KB
test_3.txt 1 ms 256 KB