結果
| 問題 |
No.908 うしたぷにきあくん文字列
|
| コンテスト | |
| ユーザー |
eSeF
|
| 提出日時 | 2019-10-20 16:21:55 |
| 言語 | C#(csc) (csc 3.9.0) |
| 結果 |
AC
|
| 実行時間 | 23 ms / 2,000 ms |
| コード長 | 1,852 bytes |
| コンパイル時間 | 931 ms |
| コンパイル使用メモリ | 108,160 KB |
| 実行使用メモリ | 17,408 KB |
| 最終ジャッジ日時 | 2024-07-02 17:27:43 |
| 合計ジャッジ時間 | 2,086 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 18 |
コンパイルメッセージ
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.IO;
using System.Text;
using static System.Math;
using static System.Array;
using static AtCoder.Tool;
namespace AtCoder
{
class AC
{
const int MOD = 1000000007;
const int INF = int.MaxValue / 2;
const long SINF = long.MaxValue / 2;
const double EPS = 1e-8;
static readonly int[] dx = { 0, 1, 0, -1 };
static readonly int[] dy = { 1, 0, -1, 0 };
static void Main(string[] args)
{
//var sw = new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false };
//Console.SetOut(sw);
var cin = new Scanner();
string s = Console.ReadLine();
bool ok = true;
for(var i = 0; i < s.Length; i++)
{
if (i % 2 == 0)
{
if(s[i] == ' ') { ok = false; }
}
else
{
if (s[i] != ' ') { ok = false; }
}
}
Console.WriteLine(ok ? "Yes" : "No");
//Console.Out.Flush();
}
}
public class Scanner
{
public int[] SplitRead()
{
int[] array = Console.ReadLine().Split().Select(int.Parse).ToArray();
return array;
}
public long[] SplitReadL()
{
long[] array = Console.ReadLine().Split().Select(long.Parse).ToArray();
return array;
}
}
public static class Tool
{
static public void Initialize<T>(ref T[] array, T initialvalue)
{
for (var i = 0; i < array.Length; i++)
{
array[i] = initialvalue;
}
}
}
}
eSeF