249402026-02-17 00:18:03pirosmacska10Morze (60 pont)cpp17Wrong answer 0/601ms536 KiB
#include <iostream>
#include <vector>
#include <algorithm>
#include <climits>
#include <string>
#include <cmath>
#include <queue>
#include <map>

using namespace std;
using ll=long long;

const ll INF=LLONG_MAX;
int main(){
    ios::sync_with_stdio(false);
    cin.tie(nullptr);

    string a;
    cin >> a;
    string ans;
    for(int i = 0; i < a.size(); i+=5) {
        string sub = a.substr(i, 5);
        cout << sub << "\n";
        if(sub == "-----") ans.push_back('0');
        else if(sub == ".----")  ans.push_back('1');
        else if(sub == "..---")  ans.push_back('2');
        else if(sub == "...--")  ans.push_back('3');
        else if(sub == "....-")  ans.push_back('4');
        else if(sub == ".....")  ans.push_back('5');
        else if(sub == "-....")  ans.push_back('6');
        else if(sub == "--...")  ans.push_back('7');
        else if(sub == "---..")  ans.push_back('8');
        else if(sub == "----.")  ans.push_back('9');
    }
    cout << ans;
}
SubtaskSumTestVerdictTimeMemory
base0/60
1Wrong answer0/01ms316 KiB
2Wrong answer0/01ms528 KiB
3Wrong answer0/31ms316 KiB
4Wrong answer0/31ms316 KiB
5Wrong answer0/31ms420 KiB
6Wrong answer0/31ms316 KiB
7Wrong answer0/31ms536 KiB
8Wrong answer0/31ms508 KiB
9Wrong answer0/41ms356 KiB
10Wrong answer0/41ms316 KiB
11Wrong answer0/41ms316 KiB
12Wrong answer0/71ms316 KiB
13Wrong answer0/71ms316 KiB
14Wrong answer0/81ms316 KiB
15Wrong answer0/81ms316 KiB