結果

問題 No.3019 YNeos
ユーザー pessimist
提出日時 2025-02-14 22:20:38
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
AC  
実行時間 42 ms / 1,000 ms
コード長 780 bytes
コンパイル時間 395 ms
コンパイル使用メモリ 12,544 KB
実行使用メモリ 10,496 KB
最終ジャッジ日時 2025-02-14 22:20:48
合計ジャッジ時間 2,973 ms
ジャッジサーバーID
(参考情報)
judge5 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 41
権限があれば一括ダウンロードができます

ソースコード

diff #

import os, sys
class FastIO:
    def __init__(self):
        self.flush = False
        return
    @staticmethod
    def read_str(): return sys.stdin.readline().rstrip()

    def st(self, x): return print(x, flush=self.flush)

    def lst(self, x): return print(*x, flush=self.flush)

class Solution:
    def __init__(self): return
    @staticmethod
    def main(ac=FastIO()):
        t = 1
        for _ in range(t):
            X=ac.read_str()
            Y=ac.read_str()
            xlen,ylen=len(X),len(Y)
            if xlen==ylen or xlen==ylen+1:
                ans=['$']*(xlen<<1) if xlen==ylen else ['$']*(xlen+ylen)
                ans[::2]=X
                ans[1::2]=Y
                ac.st(''.join(ans))
            else:
                ac.st('?')

Solution().main()
0