提出 #809321


ソースコード 拡げる

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApplication21
{
	class Program
	{
		static void Main(string[] args)
		{
			long[] L = Console.ReadLine().Split().Select(k => long.Parse(k)).ToArray();
			long n = L[0];
			long x = L[1];
			if (x > n / 2) x -= n / 2;
			long result = (n - x) * 3;
			if (x == 1 || x%n != 0) result = 3 * n - 3;
			Console.WriteLine(result);

		}
	}
}

提出情報

提出日時
問題 B - Mysterious Light
ユーザ pythagorean
言語 C# (Mono 4.6.2.0)
得点 0
コード長 491 Byte
結果 WA
実行時間 36 ms
メモリ 2776 KiB

ジャッジ結果

セット名 Sample Subtask All
得点 / 配点 0 / 0 0 / 300 0 / 200
結果
AC × 1
AC × 6
WA × 4
AC × 10
WA × 9
セット名 テストケース
Sample sample-01.txt
Subtask sample-01.txt, 01-01.txt, 01-02.txt, 01-03.txt, 01-04.txt, 01-05.txt, 01-06.txt, 01-07.txt, 01-08.txt, 01-09.txt
All sample-01.txt, 01-01.txt, 01-02.txt, 01-03.txt, 01-04.txt, 01-05.txt, 01-06.txt, 01-07.txt, 01-08.txt, 01-09.txt, 02-01.txt, 02-02.txt, 02-03.txt, 02-04.txt, 02-05.txt, 02-06.txt, 02-07.txt, 02-08.txt, 02-09.txt
ケース名 結果 実行時間 メモリ
01-01.txt AC 35 ms 2776 KiB
01-02.txt AC 35 ms 2776 KiB
01-03.txt AC 35 ms 2776 KiB
01-04.txt WA 34 ms 2776 KiB
01-05.txt WA 35 ms 2776 KiB
01-06.txt AC 35 ms 2776 KiB
01-07.txt AC 35 ms 2776 KiB
01-08.txt WA 35 ms 2776 KiB
01-09.txt WA 35 ms 2776 KiB
02-01.txt AC 35 ms 2776 KiB
02-02.txt AC 35 ms 2776 KiB
02-03.txt WA 35 ms 2776 KiB
02-04.txt WA 35 ms 2776 KiB
02-05.txt WA 35 ms 2776 KiB
02-06.txt AC 35 ms 2776 KiB
02-07.txt WA 36 ms 2776 KiB
02-08.txt WA 35 ms 2776 KiB
02-09.txt AC 35 ms 2776 KiB
sample-01.txt AC 35 ms 2776 KiB