Problem B. Censor

时间限制 0 ms   内存限制 0 MB

Censor

frog is now a editor to censor so-called sensitive words (敏感词).

She has a long text \(p\). Her job is relatively simple -- just to find the first occurence of sensitive word \(w\) and remove it.

frog repeats over and over again. Help her do the tedious work.

Input

The input consists of multiple tests. For each test:

The first line contains \(1\) string \(w\). The second line contains \(1\) string \(p\).

(\(1 \leq \textrm{length of}\ w, p \leq 5 \cdot 10^6\), \(w, p\) consists of only lowercase letter)

Output

For each test, write \(1\) string which denotes the censored text.

Sample Input

 abc
    aaabcbc
    b
    bbb
    abc
    ab

Sample Output

 a
    
    ab

提交

请先 登录

© 2025 FAQs Contact About