結果
| 問題 |
No.2201 p@$$w0rd
|
| コンテスト | |
| ユーザー |
👑 |
| 提出日時 | 2023-02-06 22:50:15 |
| 言語 | Lua (LuaJit 2.1.1734355927) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 324 bytes |
| コンパイル時間 | 185 ms |
| コンパイル使用メモリ | 7,200 KB |
| 実行使用メモリ | 6,944 KB |
| 最終ジャッジ日時 | 2024-07-05 00:29:25 |
| 合計ジャッジ時間 | 884 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 24 |
ソースコード
s = io.read()
other, lo, as = 0, 0, 0
for i = 1, 8 do
b = s:sub(i, i)
if b == "l" or b == "o" then
lo = lo + 1
elseif b == "a" or b == "s" then
as = as + 1
else
other = other + 1
end
end
local v = (bit.lshift(1, lo) - 1) * (bit.lshift(1, as) - 1)
if other == 0 then v = v - 1 end
print(math.max(0, v))