結果

問題 No.3294 UECoder
コンテスト
ユーザー 13d0ccc0-b63b-11f0-9490-db448702d40f
提出日時 2025-11-01 20:02:31
言語 TypeScript
(5.7.2)
結果
AC  
実行時間 70 ms / 2,000 ms
コード長 1,599 bytes
コンパイル時間 7,584 ms
コンパイル使用メモリ 264,300 KB
実行使用メモリ 42,496 KB
最終ジャッジ日時 2025-11-01 20:02:42
合計ジャッジ時間 10,471 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 20
権限があれば一括ダウンロードができます

ソースコード

diff #

import * as fs from 'fs';

let inputs = '';
let inputArray: string[];
let currentIndex = 0;
let outputBuffer = '';

const flush = () => console.log(outputBuffer.trim());
const next = () => inputArray[currentIndex++];
const nextBigInt = (): BigInt => BigInt(next());
const nextBigInts = (length: number): BigInt[] => Array.from({ length: length }, () => nextBigInt());
const nextNum = () => +next();
const nextNums = (length: number): number[] => Array.from({ length: length }, () => nextNum());
const nexts = (length: number): string[] => Array.from({ length: length }, () => next());
function print(out: string | number | bigint): void;
function print<T>(out: Array<T>, separator: string): void;
function print<T>(out: string | number | bigint | Array<T>, separator?: string): void {
    if (Array.isArray(out)) {
        outputBuffer += out.join(separator);
    } else {
        outputBuffer += out;
    }
}
function println(out: string | number | bigint): void;
function println<T>(out: Array<T>, separator: string): void;
function println<T>(out: string | number | bigint | Array<T>, separator?: string) {
    if (Array.isArray(out)) {
        print(out, separator || '');
    } else {
        print(out);
    }
    print('\n');
}

inputs = fs.readFileSync('/dev/stdin', 'utf8');
inputArray = inputs.split(/\s/);
main();
flush();

function main() {
    const n = nextNum();
    const s = next();
    const pos = s.indexOf('c');
    println(`UEC${s.slice(pos + 1)}`);
}

function minBigInt(x: BigInt, y: BigInt): BigInt {
    if (x > y) {
        return y;
    } else {
        return x;
    }
}
0