結果

問題 No.2246 1333-like Number
ユーザー bluemegane
提出日時 2023-03-17 22:42:07
言語 C#(csc)
(csc 3.9.0)
結果
WA  
実行時間 -
コード長 548 bytes
コンパイル時間 5,488 ms
コンパイル使用メモリ 110,880 KB
実行使用メモリ 25,808 KB
最終ジャッジ日時 2024-09-18 11:49:35
合計ジャッジ時間 7,306 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2 WA * 1
other AC * 6 WA * 14 RE * 4
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc)
Copyright (C) Microsoft Corporation. All rights reserved.

ソースコード

diff #

using System.Collections.Generic;
using System;

public class Hello
{
    static void Main()
    {
        var n = int.Parse(Console.ReadLine().Trim());
        getAns(n);
    }
    static void getAns(int n)
    {
        var a = new List<int>() { 0 };
        for (int i = 1; i <= 9; i++)
            for (int j = i + 1; j < 9; j++) a.Add(i * 10 + j);
        var s = n / 36;
        var r = n % 36;
        Console.Write(a[r]);
        var c = a[r] % 10;
        for (int i = 0; i < s; i++) Console.Write(c);
        Console.WriteLine();
    }
}
0