CSES - KILO 2016 4/5 - Results
Submission details
Task:Blocks
Sender:Kaeaepae
Submission time:2016-09-27 16:38:18 +0300
Language:C++
Status:READY
Result:
Test results
testverdicttime
#10.05 sdetails
#20.06 sdetails
#30.07 sdetails
#40.07 sdetails
#50.06 sdetails
#60.06 sdetails
#70.05 sdetails
#80.06 sdetails
#90.05 sdetails
#100.05 sdetails
#110.05 sdetails
#120.06 sdetails
#130.06 sdetails
#140.05 sdetails
#150.06 sdetails
#160.06 sdetails
#170.04 sdetails
#180.06 sdetails
#190.06 sdetails
#200.06 sdetails
#210.04 sdetails
#220.06 sdetails
#230.05 sdetails
#240.07 sdetails
#250.06 sdetails
#260.06 sdetails
#270.06 sdetails
#280.06 sdetails
#290.06 sdetails
#300.06 sdetails

Code

#include <iostream>
#include <cassert>
#include <map>
#include <tuple>
#include <bitset>

using namespace std;

int main() {
  cin.sync_with_stdio(false);

  string s;
  cin >> s;

  int mer = 0, atat = 0, gcgc = 0;
  for (char c: s) {
    int base = (c == 'A' ? 1
		: c == 'T' ? 2
		: c == 'G' ? 3
		: c == 'C' ? 4
		: 0);
    mer = ((mer << 3) + base) & 07777;
    atat += (mer == 01212);
    gcgc += (mer == 03434);
  }

  cout << ( atat > gcgc ? "Kaaleppi"
	    : atat < gcgc ? "Maija"
	    : "not sure" ) << "\n"; 
}

Test details

Test 1

Verdict:

input
5
1 2 3 4 5

correct output
5

user output
not sure

Test 2

Verdict:

input
3
2000 1999 1998

correct output
1

user output
not sure

Test 3

Verdict:

input
6
888947812 255632128 310470259 ...

correct output
3

user output
not sure

Test 4

Verdict:

input
4
617082542 842820809 770021951 ...

correct output
3

user output
not sure

Test 5

Verdict:

input
8
714278219 784227423 409319089 ...

correct output
2

user output
not sure

Test 6

Verdict:

input
4
323548620 170481297 889562264 ...

correct output
2

user output
not sure

Test 7

Verdict:

input
1
476683151

correct output
1

user output
not sure

Test 8

Verdict:

input
2
629714376 581892911

correct output
1

user output
not sure

Test 9

Verdict:

input
6
523198668 325464999 948349338 ...

correct output
2

user output
not sure

Test 10

Verdict:

input
6
822568264 254647499 434272192 ...

correct output
4

user output
not sure

Test 11

Verdict:

input
433
1 2 3 4 5 6 7 8 9 10 11 12 13 ...

correct output
433

user output
not sure

Test 12

Verdict:

input
554
2000 1999 1998 1997 1996 1995 ...

correct output
1

user output
not sure

Test 13

Verdict:

input
630
882563506 195731667 430976596 ...

correct output
49

user output
not sure

Test 14

Verdict:

input
335
488807609 178110205 512054465 ...

correct output
33

user output
not sure

Test 15

Verdict:

input
120
174580714 91110553 34218342 94...

correct output
20

user output
not sure

Test 16

Verdict:

input
593
34099449 759420722 786869557 3...

correct output
41

user output
not sure

Test 17

Verdict:

input
97
393681127 117745478 576906971 ...

correct output
16

user output
not sure

Test 18

Verdict:

input
780
596776372 178963013 27288301 3...

correct output
56

user output
not sure

Test 19

Verdict:

input
769
927650514 16537731 669979959 5...

correct output
53

user output
not sure

Test 20

Verdict:

input
253
939795028 916965543 553106661 ...

correct output
26

user output
not sure

Test 21

Verdict:

input
1000
1 2 3 4 5 6 7 8 9 10 11 12 13 ...

correct output
1000

user output
not sure

Test 22

Verdict:

input
1000
2000 1999 1998 1997 1996 1995 ...

correct output
1

user output
not sure

Test 23

Verdict:

input
1000
645404707 986143091 145611946 ...

correct output
58

user output
not sure

Test 24

Verdict:

input
1000
341727972 757181419 834201886 ...

correct output
56

user output
not sure

Test 25

Verdict:

input
1000
140851913 102736547 916629519 ...

correct output
55

user output
not sure

Test 26

Verdict:

input
1000
32986064 260267921 970027433 9...

correct output
64

user output
not sure

Test 27

Verdict:

input
1000
164970760 259631575 668929944 ...

correct output
54

user output
not sure

Test 28

Verdict:

input
1000
259307867 630607450 309297823 ...

correct output
56

user output
not sure

Test 29

Verdict:

input
1000
543833880 613702937 41531951 2...

correct output
58

user output
not sure

Test 30

Verdict:

input
1000
652483687 571130341 552217195 ...

correct output
59

user output
not sure