結果
| 問題 |
No.820 Power of Two
|
| コンテスト | |
| ユーザー |
udon
|
| 提出日時 | 2019-05-26 15:20:28 |
| 言語 | C#(csc) (csc 3.9.0) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 498 bytes |
| コンパイル時間 | 910 ms |
| コンパイル使用メモリ | 107,796 KB |
| 実行使用メモリ | 25,432 KB |
| 最終ジャッジ日時 | 2024-09-17 15:15:30 |
| 合計ジャッジ時間 | 1,726 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | RE * 10 |
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc) Copyright (C) Microsoft Corporation. All rights reserved.
ソースコード
using System;
class Program
{
static void Main(string[] args)
{
var line = Console.ReadLine();
string[] arg = line.Split(' ');
int[] numArgs = new int[arg.Length];
for(int i = 0; i < numArgs.Length; ++i)
{
numArgs[i] = int.Parse(args[i]);
}
int pow = numArgs[0] >= numArgs[1] ? (int) Math.Pow(2, numArgs[0] - numArgs[1]) : 0;
Console.WriteLine(pow);
}
}
udon