AtCoder Regular Contest 082

Submission #1567250

Source codeソースコード

M=998244353;N=gets.to_i;v=$<.map{|e|Complex(*e.split.map(&:to_i))};h={};r=2**N%M-N-1;N.times{|i|(i+1...N).map{|j|h[x=[i,j]]||(j+1...N).map{|k|((v[j]-v[k]).conj*(v[i]-v[k])).imag.abs<1e-9&&x<<k}&&(l=x.size).times{|a|(a+1...l).map{|b|r=(r-2**(b+~a))%M;h[[x[a],x[b]]]=1}}}};p r

Submission

Task問題 E - ConvexScore
User nameユーザ名 cf16::002_ciel
Created time投稿日時
Language言語 Ruby (2.3.3)
Status状態 AC
Score得点 700
Source lengthソースコード長 274 Byte
File nameファイル名
Exec time実行時間 1921 ms
Memory usageメモリ使用量 7036 KB

Test case

Set

Set name Score得点 / Max score Cases
Sample - 0_000.txt,0_001.txt,0_002.txt
All 700 / 700 0_000.txt,0_001.txt,0_002.txt,1_003.txt,1_004.txt,1_005.txt,1_006.txt,1_007.txt,1_008.txt,1_009.txt,1_010.txt,1_011.txt,1_012.txt,1_013.txt,1_014.txt,1_015.txt,1_016.txt,1_017.txt,1_018.txt,1_019.txt,1_020.txt,1_021.txt,1_022.txt,1_023.txt,1_024.txt,1_025.txt,1_026.txt,1_027.txt,1_028.txt,1_029.txt,1_030.txt,1_031.txt,1_032.txt,1_033.txt,1_034.txt,1_035.txt

Test case

Case name Status状態 Exec time実行時間 Memory usageメモリ使用量
0_000.txt AC 7 ms 1788 KB
0_001.txt AC 7 ms 1788 KB
0_002.txt AC 7 ms 1788 KB
1_003.txt AC 7 ms 1788 KB
1_004.txt AC 7 ms 1788 KB
1_005.txt AC 482 ms 3196 KB
1_006.txt AC 7 ms 1788 KB
1_007.txt AC 592 ms 3580 KB
1_008.txt AC 369 ms 3324 KB
1_009.txt AC 547 ms 3452 KB
1_010.txt AC 127 ms 2300 KB
1_011.txt AC 697 ms 3452 KB
1_012.txt AC 876 ms 3580 KB
1_013.txt AC 440 ms 3196 KB
1_014.txt AC 10 ms 1788 KB
1_015.txt AC 54 ms 3708 KB
1_016.txt AC 27 ms 2556 KB
1_017.txt AC 1921 ms 5116 KB
1_018.txt AC 1916 ms 7036 KB
1_019.txt AC 1069 ms 5116 KB
1_020.txt AC 1035 ms 5116 KB
1_021.txt AC 1202 ms 5116 KB
1_022.txt AC 1466 ms 5116 KB
1_023.txt AC 1773 ms 5116 KB
1_024.txt AC 1690 ms 5116 KB
1_025.txt AC 1550 ms 5116 KB
1_026.txt AC 1533 ms 5116 KB
1_027.txt AC 82 ms 4732 KB
1_028.txt AC 82 ms 4732 KB
1_029.txt AC 1542 ms 5116 KB
1_030.txt AC 1856 ms 5116 KB
1_031.txt AC 1857 ms 5116 KB
1_032.txt AC 1843 ms 5116 KB
1_033.txt AC 1921 ms 5116 KB
1_034.txt AC 1897 ms 5116 KB
1_035.txt AC 1102 ms 4988 KB