結果
問題 |
No.538 N.G.S.
|
ユーザー |
|
提出日時 | 2017-07-08 01:23:35 |
言語 | C#(csc) (csc 3.9.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 597 bytes |
コンパイル時間 | 2,166 ms |
コンパイル使用メモリ | 103,424 KB |
実行使用メモリ | 18,176 KB |
最終ジャッジ日時 | 2024-10-06 10:14:36 |
合計ジャッジ時間 | 3,885 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 37 WA * 14 |
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc) Copyright (C) Microsoft Corporation. All rights reserved.
ソースコード
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace NGS { class Program { static void Main(string[] args) { var inputs = Console.ReadLine().Split(' '); var a1 = Double.Parse(inputs[0]); var a2 = Double.Parse(inputs[1]); var a3 = Double.Parse(inputs[2]); Double r = (a2 - a3) / (a1 - a2); Double d = a2 - (r * a1); var result = (Int32)((a3 * r) + d); Console.Write(result + "\n"); } } }