結果
問題 |
No.2051 Divide
|
ユーザー |
👑 |
提出日時 | 2022-08-23 22:43:27 |
言語 | Lua (LuaJit 2.1.1734355927) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 308 bytes |
コンパイル時間 | 33 ms |
コンパイル使用メモリ | 6,692 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-10-11 05:22:29 |
合計ジャッジ時間 | 884 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 23 |
ソースコード
local a, b = io.read("*n", "*n") local c = 0 for i = 1, 100000 do if a % i == 0 then local j = math.floor(a / i) if i < j then if i % b == 0 then c = c + 1 end if j % b == 0 then c = c + 1 end elseif i == j then if i % b == 0 then c = c + 1 end end end end print(c)