結果

問題 No.2773 Wake up Record 1
ユーザー 👑 kakel-sankakel-san
提出日時 2024-06-07 21:21:58
言語 C#
(.NET 8.0.203)
結果
AC  
実行時間 70 ms / 2,000 ms
コード長 599 bytes
コンパイル時間 8,146 ms
コンパイル使用メモリ 169,996 KB
実行使用メモリ 189,484 KB
最終ジャッジ日時 2024-06-07 21:22:09
合計ジャッジ時間 10,398 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 46 ms
30,080 KB
testcase_01 AC 45 ms
29,952 KB
testcase_02 AC 47 ms
30,080 KB
testcase_03 AC 47 ms
29,696 KB
testcase_04 AC 47 ms
29,952 KB
testcase_05 AC 58 ms
32,252 KB
testcase_06 AC 55 ms
31,232 KB
testcase_07 AC 57 ms
32,128 KB
testcase_08 AC 55 ms
31,360 KB
testcase_09 AC 55 ms
31,608 KB
testcase_10 AC 55 ms
31,488 KB
testcase_11 AC 57 ms
32,128 KB
testcase_12 AC 55 ms
31,616 KB
testcase_13 AC 56 ms
30,968 KB
testcase_14 AC 70 ms
31,232 KB
testcase_15 AC 48 ms
30,464 KB
testcase_16 AC 60 ms
32,128 KB
testcase_17 AC 64 ms
31,616 KB
testcase_18 AC 63 ms
31,100 KB
testcase_19 AC 60 ms
32,384 KB
testcase_20 AC 55 ms
30,968 KB
testcase_21 AC 56 ms
32,000 KB
testcase_22 AC 57 ms
32,124 KB
testcase_23 AC 58 ms
32,128 KB
testcase_24 AC 56 ms
189,484 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
  復元対象のプロジェクトを決定しています...
  /home/judge/data/code/main.csproj を復元しました (139 ms)。
MSBuild のバージョン 17.9.6+a4ecab324 (.NET)
  main -> /home/judge/data/code/bin/Release/net8.0/main.dll
  main -> /home/judge/data/code/bin/Release/net8.0/publish/

ソースコード

diff #

using System;
using static System.Console;
using System.Linq;
using System.Collections.Generic;

class Program
{
    static int NN => int.Parse(ReadLine());
    static int[] NList => ReadLine().Split().Select(int.Parse).ToArray();
    public static void Main()
    {
        Solve();
    }
    static void Solve()
    {
        var n = NN;
        var s = ReadLine();
        var ans = new List<int>();
        for (var i = 1; i < s.Length; ++i) if (s[i - 1] == 'x' && s[i] == 'o') ans.Add(i + 1);
        WriteLine(ans.Count);
        WriteLine(string.Join(" ", ans));
    }
}
0