답안 #1015912

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
1015912 2024-07-07T04:36:28 Z isaachew Bliskost (COI23_bliskost) C++17
100 / 100
118 ms 16464 KB
#include <bits/stdc++.h>

int main(){
    std::ios::sync_with_stdio(0);
    std::cin.tie(0);
    int n,q;
    std::cin>>n>>q;
    std::string st1,st2;
    std::cin>>st1>>st2;
    int taltsum=0;
    for(int i=0;i<n;i++){
        taltsum+=i%2?-st1[i]:st1[i];
        taltsum-=i%2?-st2[i]:st2[i];
    }
    std::cout<<(taltsum%26==0?"da\n":"ne\n");
    for(int i=0;i<q;i++){
        int a;
        char c;
        std::cin>>a>>c;
        a--;
        taltsum-=a%2?-st1[a]:st1[a];
        st1[a]=c;
        taltsum+=a%2?-c:c;
        std::cout<<(taltsum%26==0?"da\n":"ne\n");
    }
}
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 0 ms 348 KB Output is correct
5 Correct 0 ms 348 KB Output is correct
6 Correct 0 ms 348 KB Output is correct
7 Correct 0 ms 348 KB Output is correct
8 Correct 0 ms 348 KB Output is correct
9 Correct 0 ms 348 KB Output is correct
10 Correct 0 ms 348 KB Output is correct
11 Correct 0 ms 348 KB Output is correct
12 Correct 0 ms 348 KB Output is correct
13 Correct 0 ms 348 KB Output is correct
14 Correct 0 ms 348 KB Output is correct
15 Correct 0 ms 348 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 0 ms 348 KB Output is correct
5 Correct 0 ms 348 KB Output is correct
6 Correct 0 ms 348 KB Output is correct
7 Correct 0 ms 348 KB Output is correct
8 Correct 0 ms 348 KB Output is correct
9 Correct 0 ms 348 KB Output is correct
10 Correct 0 ms 348 KB Output is correct
11 Correct 0 ms 348 KB Output is correct
12 Correct 0 ms 348 KB Output is correct
13 Correct 0 ms 348 KB Output is correct
14 Correct 0 ms 348 KB Output is correct
15 Correct 0 ms 348 KB Output is correct
16 Correct 0 ms 348 KB Output is correct
17 Correct 0 ms 348 KB Output is correct
18 Correct 0 ms 348 KB Output is correct
19 Correct 0 ms 348 KB Output is correct
20 Correct 0 ms 348 KB Output is correct
21 Correct 0 ms 348 KB Output is correct
22 Correct 0 ms 348 KB Output is correct
23 Correct 0 ms 348 KB Output is correct
24 Correct 1 ms 348 KB Output is correct
25 Correct 0 ms 348 KB Output is correct
26 Correct 0 ms 348 KB Output is correct
27 Correct 0 ms 344 KB Output is correct
28 Correct 1 ms 348 KB Output is correct
29 Correct 0 ms 348 KB Output is correct
30 Correct 0 ms 348 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 0 ms 348 KB Output is correct
5 Correct 0 ms 348 KB Output is correct
6 Correct 0 ms 348 KB Output is correct
7 Correct 0 ms 348 KB Output is correct
8 Correct 0 ms 348 KB Output is correct
9 Correct 0 ms 348 KB Output is correct
10 Correct 0 ms 348 KB Output is correct
11 Correct 0 ms 348 KB Output is correct
12 Correct 0 ms 348 KB Output is correct
13 Correct 0 ms 348 KB Output is correct
14 Correct 0 ms 348 KB Output is correct
15 Correct 0 ms 348 KB Output is correct
16 Correct 0 ms 348 KB Output is correct
17 Correct 0 ms 348 KB Output is correct
18 Correct 0 ms 348 KB Output is correct
19 Correct 0 ms 348 KB Output is correct
20 Correct 0 ms 348 KB Output is correct
21 Correct 0 ms 348 KB Output is correct
22 Correct 0 ms 348 KB Output is correct
23 Correct 0 ms 348 KB Output is correct
24 Correct 1 ms 348 KB Output is correct
25 Correct 0 ms 348 KB Output is correct
26 Correct 0 ms 348 KB Output is correct
27 Correct 0 ms 344 KB Output is correct
28 Correct 1 ms 348 KB Output is correct
29 Correct 0 ms 348 KB Output is correct
30 Correct 0 ms 348 KB Output is correct
31 Correct 3 ms 2808 KB Output is correct
32 Correct 6 ms 2808 KB Output is correct
33 Correct 3 ms 2808 KB Output is correct
34 Correct 4 ms 2808 KB Output is correct
35 Correct 4 ms 2808 KB Output is correct
36 Correct 5 ms 2808 KB Output is correct
37 Correct 3 ms 2808 KB Output is correct
38 Correct 3 ms 2808 KB Output is correct
39 Correct 3 ms 2808 KB Output is correct
40 Correct 3 ms 2808 KB Output is correct
41 Correct 3 ms 2808 KB Output is correct
42 Correct 3 ms 2896 KB Output is correct
43 Correct 3 ms 2808 KB Output is correct
44 Correct 3 ms 2808 KB Output is correct
45 Correct 3 ms 2724 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 0 ms 348 KB Output is correct
5 Correct 0 ms 348 KB Output is correct
6 Correct 0 ms 348 KB Output is correct
7 Correct 0 ms 348 KB Output is correct
8 Correct 0 ms 348 KB Output is correct
9 Correct 0 ms 348 KB Output is correct
10 Correct 0 ms 348 KB Output is correct
11 Correct 0 ms 348 KB Output is correct
12 Correct 0 ms 348 KB Output is correct
13 Correct 0 ms 348 KB Output is correct
14 Correct 0 ms 348 KB Output is correct
15 Correct 0 ms 348 KB Output is correct
16 Correct 6 ms 604 KB Output is correct
17 Correct 6 ms 656 KB Output is correct
18 Correct 5 ms 604 KB Output is correct
19 Correct 6 ms 604 KB Output is correct
20 Correct 6 ms 604 KB Output is correct
21 Correct 6 ms 744 KB Output is correct
22 Correct 5 ms 604 KB Output is correct
23 Correct 5 ms 604 KB Output is correct
24 Correct 6 ms 604 KB Output is correct
25 Correct 5 ms 604 KB Output is correct
26 Correct 6 ms 604 KB Output is correct
27 Correct 6 ms 604 KB Output is correct
28 Correct 6 ms 572 KB Output is correct
29 Correct 6 ms 704 KB Output is correct
30 Correct 5 ms 604 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 0 ms 348 KB Output is correct
5 Correct 0 ms 348 KB Output is correct
6 Correct 0 ms 348 KB Output is correct
7 Correct 0 ms 348 KB Output is correct
8 Correct 0 ms 348 KB Output is correct
9 Correct 0 ms 348 KB Output is correct
10 Correct 0 ms 348 KB Output is correct
11 Correct 0 ms 348 KB Output is correct
12 Correct 0 ms 348 KB Output is correct
13 Correct 0 ms 348 KB Output is correct
14 Correct 0 ms 348 KB Output is correct
15 Correct 0 ms 348 KB Output is correct
16 Correct 0 ms 348 KB Output is correct
17 Correct 0 ms 348 KB Output is correct
18 Correct 0 ms 348 KB Output is correct
19 Correct 0 ms 348 KB Output is correct
20 Correct 0 ms 348 KB Output is correct
21 Correct 0 ms 348 KB Output is correct
22 Correct 0 ms 348 KB Output is correct
23 Correct 0 ms 348 KB Output is correct
24 Correct 1 ms 348 KB Output is correct
25 Correct 0 ms 348 KB Output is correct
26 Correct 0 ms 348 KB Output is correct
27 Correct 0 ms 344 KB Output is correct
28 Correct 1 ms 348 KB Output is correct
29 Correct 0 ms 348 KB Output is correct
30 Correct 0 ms 348 KB Output is correct
31 Correct 6 ms 604 KB Output is correct
32 Correct 6 ms 656 KB Output is correct
33 Correct 5 ms 604 KB Output is correct
34 Correct 6 ms 604 KB Output is correct
35 Correct 6 ms 604 KB Output is correct
36 Correct 6 ms 744 KB Output is correct
37 Correct 5 ms 604 KB Output is correct
38 Correct 5 ms 604 KB Output is correct
39 Correct 6 ms 604 KB Output is correct
40 Correct 5 ms 604 KB Output is correct
41 Correct 6 ms 604 KB Output is correct
42 Correct 6 ms 604 KB Output is correct
43 Correct 6 ms 572 KB Output is correct
44 Correct 6 ms 704 KB Output is correct
45 Correct 5 ms 604 KB Output is correct
46 Correct 7 ms 560 KB Output is correct
47 Correct 6 ms 604 KB Output is correct
48 Correct 6 ms 600 KB Output is correct
49 Correct 7 ms 608 KB Output is correct
50 Correct 6 ms 604 KB Output is correct
51 Correct 7 ms 604 KB Output is correct
52 Correct 7 ms 708 KB Output is correct
53 Correct 7 ms 604 KB Output is correct
54 Correct 6 ms 732 KB Output is correct
55 Correct 6 ms 604 KB Output is correct
56 Correct 6 ms 604 KB Output is correct
57 Correct 6 ms 604 KB Output is correct
58 Correct 7 ms 732 KB Output is correct
59 Correct 6 ms 604 KB Output is correct
60 Correct 6 ms 520 KB Output is correct
# 결과 실행 시간 메모리 Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Correct 0 ms 348 KB Output is correct
4 Correct 0 ms 348 KB Output is correct
5 Correct 0 ms 348 KB Output is correct
6 Correct 0 ms 348 KB Output is correct
7 Correct 0 ms 348 KB Output is correct
8 Correct 0 ms 348 KB Output is correct
9 Correct 0 ms 348 KB Output is correct
10 Correct 0 ms 348 KB Output is correct
11 Correct 0 ms 348 KB Output is correct
12 Correct 0 ms 348 KB Output is correct
13 Correct 0 ms 348 KB Output is correct
14 Correct 0 ms 348 KB Output is correct
15 Correct 0 ms 348 KB Output is correct
16 Correct 0 ms 348 KB Output is correct
17 Correct 0 ms 348 KB Output is correct
18 Correct 0 ms 348 KB Output is correct
19 Correct 0 ms 348 KB Output is correct
20 Correct 0 ms 348 KB Output is correct
21 Correct 0 ms 348 KB Output is correct
22 Correct 0 ms 348 KB Output is correct
23 Correct 0 ms 348 KB Output is correct
24 Correct 1 ms 348 KB Output is correct
25 Correct 0 ms 348 KB Output is correct
26 Correct 0 ms 348 KB Output is correct
27 Correct 0 ms 344 KB Output is correct
28 Correct 1 ms 348 KB Output is correct
29 Correct 0 ms 348 KB Output is correct
30 Correct 0 ms 348 KB Output is correct
31 Correct 3 ms 2808 KB Output is correct
32 Correct 6 ms 2808 KB Output is correct
33 Correct 3 ms 2808 KB Output is correct
34 Correct 4 ms 2808 KB Output is correct
35 Correct 4 ms 2808 KB Output is correct
36 Correct 5 ms 2808 KB Output is correct
37 Correct 3 ms 2808 KB Output is correct
38 Correct 3 ms 2808 KB Output is correct
39 Correct 3 ms 2808 KB Output is correct
40 Correct 3 ms 2808 KB Output is correct
41 Correct 3 ms 2808 KB Output is correct
42 Correct 3 ms 2896 KB Output is correct
43 Correct 3 ms 2808 KB Output is correct
44 Correct 3 ms 2808 KB Output is correct
45 Correct 3 ms 2724 KB Output is correct
46 Correct 6 ms 604 KB Output is correct
47 Correct 6 ms 656 KB Output is correct
48 Correct 5 ms 604 KB Output is correct
49 Correct 6 ms 604 KB Output is correct
50 Correct 6 ms 604 KB Output is correct
51 Correct 6 ms 744 KB Output is correct
52 Correct 5 ms 604 KB Output is correct
53 Correct 5 ms 604 KB Output is correct
54 Correct 6 ms 604 KB Output is correct
55 Correct 5 ms 604 KB Output is correct
56 Correct 6 ms 604 KB Output is correct
57 Correct 6 ms 604 KB Output is correct
58 Correct 6 ms 572 KB Output is correct
59 Correct 6 ms 704 KB Output is correct
60 Correct 5 ms 604 KB Output is correct
61 Correct 7 ms 560 KB Output is correct
62 Correct 6 ms 604 KB Output is correct
63 Correct 6 ms 600 KB Output is correct
64 Correct 7 ms 608 KB Output is correct
65 Correct 6 ms 604 KB Output is correct
66 Correct 7 ms 604 KB Output is correct
67 Correct 7 ms 708 KB Output is correct
68 Correct 7 ms 604 KB Output is correct
69 Correct 6 ms 732 KB Output is correct
70 Correct 6 ms 604 KB Output is correct
71 Correct 6 ms 604 KB Output is correct
72 Correct 6 ms 604 KB Output is correct
73 Correct 7 ms 732 KB Output is correct
74 Correct 6 ms 604 KB Output is correct
75 Correct 6 ms 520 KB Output is correct
76 Correct 80 ms 6812 KB Output is correct
77 Correct 91 ms 16464 KB Output is correct
78 Correct 92 ms 16040 KB Output is correct
79 Correct 98 ms 16244 KB Output is correct
80 Correct 84 ms 16060 KB Output is correct
81 Correct 89 ms 16004 KB Output is correct
82 Correct 97 ms 16016 KB Output is correct
83 Correct 85 ms 16084 KB Output is correct
84 Correct 102 ms 16200 KB Output is correct
85 Correct 100 ms 16056 KB Output is correct
86 Correct 94 ms 16432 KB Output is correct
87 Correct 98 ms 16452 KB Output is correct
88 Correct 110 ms 16396 KB Output is correct
89 Correct 93 ms 16104 KB Output is correct
90 Correct 118 ms 16376 KB Output is correct