結果

問題 No.723 2つの数の和
ユーザー letrangerjpletrangerjp
提出日時 2018-08-03 23:14:19
言語 Ruby
(3.3.0)
結果
AC  
実行時間 230 ms / 2,000 ms
コード長 92 bytes
コンパイル時間 146 ms
コンパイル使用メモリ 11,924 KB
実行使用メモリ 34,452 KB
最終ジャッジ日時 2023-10-19 21:39:07
合計ジャッジ時間 4,986 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 87 ms
16,108 KB
testcase_01 AC 89 ms
16,108 KB
testcase_02 AC 87 ms
16,108 KB
testcase_03 AC 181 ms
28,712 KB
testcase_04 AC 214 ms
33,300 KB
testcase_05 AC 195 ms
31,412 KB
testcase_06 AC 201 ms
31,640 KB
testcase_07 AC 138 ms
23,000 KB
testcase_08 AC 154 ms
24,056 KB
testcase_09 AC 214 ms
33,656 KB
testcase_10 AC 136 ms
22,568 KB
testcase_11 AC 98 ms
17,468 KB
testcase_12 AC 155 ms
25,500 KB
testcase_13 AC 216 ms
34,360 KB
testcase_14 AC 128 ms
20,080 KB
testcase_15 AC 148 ms
23,484 KB
testcase_16 AC 165 ms
27,100 KB
testcase_17 AC 191 ms
30,792 KB
testcase_18 AC 165 ms
33,532 KB
testcase_19 AC 176 ms
34,100 KB
testcase_20 AC 87 ms
16,108 KB
testcase_21 AC 87 ms
16,108 KB
testcase_22 AC 87 ms
16,108 KB
testcase_23 AC 230 ms
34,452 KB
testcase_24 AC 127 ms
21,704 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

eval"N,X,*A="+gets(p).split*?,
h=A.group_by{|x|x}
p h.map{|k,v|v.size*(h[X-k]||[]).size}.sum
0