結果
問題 | No.1175 Simultaneous Equations |
ユーザー |
![]() |
提出日時 | 2021-07-07 07:01:23 |
言語 | C#(csc) (csc 3.9.0) |
結果 |
AC
|
実行時間 | 27 ms / 2,000 ms |
コード長 | 596 bytes |
コンパイル時間 | 3,123 ms |
コンパイル使用メモリ | 102,656 KB |
実行使用メモリ | 18,944 KB |
最終ジャッジ日時 | 2024-07-01 12:17:05 |
合計ジャッジ時間 | 4,223 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 11 |
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc) Copyright (C) Microsoft Corporation. All rights reserved.
ソースコード
using System;public class Hello{public static int a, b, c, d, e, f;static void Main(){string[] line = Console.ReadLine().Trim().Split(' ');a = int.Parse(line[0]);b = int.Parse(line[1]);c = int.Parse(line[2]);d = int.Parse(line[3]);e = int.Parse(line[4]);f = int.Parse(line[5]);getAns();}static void getAns(){var t1 = c * d - a * f;var t2 = b * d - a * e;var y = (double)t1 / t2;var x = (c - b * y) / a;Console.WriteLine("{0} {1}", x, y);}}