結果
問題 | No.138 化石のバージョン |
ユーザー |
|
提出日時 | 2020-06-20 21:52:39 |
言語 | C#(csc) (csc 3.9.0) |
結果 |
AC
|
実行時間 | 30 ms / 5,000 ms |
コード長 | 774 bytes |
コンパイル時間 | 874 ms |
コンパイル使用メモリ | 113,752 KB |
実行使用メモリ | 29,444 KB |
最終ジャッジ日時 | 2024-07-03 17:34:50 |
合計ジャッジ時間 | 2,996 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 33 |
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc) Copyright (C) Microsoft Corporation. All rights reserved.
ソースコード
using System;using System.Linq;namespace _0138{class Program{static void Main(string[] args){var s1 = Console.ReadLine().Split('.').Select(x => int.Parse(x)).ToArray();var t1 = string.Format("{0:000}",s1[0]) + string.Format("{0:000}",s1[1]) + string.Format("{0:000}",s1[2]);var n1 = int.Parse(t1);var s2 = Console.ReadLine().Split('.').Select(x => int.Parse(x)).ToArray();var t2 = string.Format("{0:000}",s2[0]) + string.Format("{0:000}",s2[1]) + string.Format("{0:000}",s2[2]);var n2 = int.Parse(t2);if(n2 <= n1){Console.WriteLine("YES");}else{Console.WriteLine("NO");}}}}