結果

問題 No.1476 esreveR dna esreveR
ユーザー さかぽんさかぽん
提出日時 2021-04-16 22:42:34
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 56 ms / 2,000 ms
コード長 300 bytes
コンパイル時間 2,142 ms
コンパイル使用メモリ 100,740 KB
実行使用メモリ 22,788 KB
最終ジャッジ日時 2023-09-16 01:47:38
合計ジャッジ時間 3,175 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 56 ms
22,724 KB
testcase_01 AC 56 ms
22,788 KB
testcase_02 AC 56 ms
20,860 KB
testcase_03 AC 54 ms
20,744 KB
testcase_04 AC 54 ms
20,856 KB
testcase_05 AC 55 ms
22,784 KB
testcase_06 AC 55 ms
22,728 KB
testcase_07 AC 54 ms
18,792 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc)
Copyright (C) Microsoft Corporation. All rights reserved.

ソースコード

diff #

using System;

class A
{
	static void Main()
	{
		var n = long.Parse(Console.ReadLine());
		Console.WriteLine(MPow(6, n / 2));
	}

	const long M = 998244353;
	static long MPow(long b, long i)
	{
		long r = 1;
		for (; i != 0; b = b * b % M, i >>= 1) if ((i & 1) != 0) r = r * b % M;
		return r;
	}
}
0