TnT/Multi_CodeNet4Repair huggingface dataset:
Problem: For two sequences S and T of length N consisting of 0 and 1, let us define f(S, T) as follows:    * Consider repeating the following operation on S so that S will be equal to T. f(S, T) is the minimum possible total cost of those operations.      * Change S_i (from 0 to 1 or vice versa). The cost of this operation is D \times C_i, where D is the number of integers j such that S_j \neq T_j (1 \leq j \leq N) just before this change.  There are 2^N \times (2^N - 1) pairs (S, T) of different sequences of length N consisting of 0 and 1. Compute the sum of f(S, T) over all of those pairs, modulo (10^9+7).

Submission attempts (in order):
import sys
INF=1e9
mod=1e9+7
n=int(input())
lit=list(map(int,input().split()))
lit.sort()
ans=0
for i in range(n):
    ans=(ans+lit[i]*(n-i+1)%mod)%mod
for i in range(2*(n-1)):
    ans=ans*2%mod
print(ans)


import sys
INF=1e9
mod=1e9+7
n=int(input())
lit=list(map(int,input().split()))
lit.sort()
ans=0
for i in range(n):
    ans=(ans+lit[i]*(n-i+1)%mod)%mod
for i in range((n-1)):
    ans=ans*4%mod
ans=int(ans)
print(ans)


Verdicts: Wrong Answer

Accepted
Problem: For two sequences S and T of length N consisting of 0 and 1, let us define f(S, T) as follows:    * Consider repeating the following operation on S so that S will be equal to T. f(S, T) is the minimum possible total cost of those operations.      * Change S_i (from 0 to 1 or vice versa). The cost of this operation is D \times C_i, where D is the number of integers j such that S_j \neq T_j (1 \leq j \leq N) just before this change.  There are 2^N \times (2^N - 1) pairs (S, T) of different sequences of length N consisting of 0 and 1. Compute the sum of f(S, T) over all of those pairs, modulo (10^9+7).

Submission attempts (in order):
MOD = 10 ** 9 + 7
N = int(input())
C = list(map(int, input().split()))
C.sort()


lst = [0] * (N + 3)
lst[0] = 1
for i in range(1, N + 3):
    lst[i] = (lst[i - 1] * 2) % MOD


ANS = 0
for i, c in enumerate(C):
    ANS += c * (N + 1 - i)

ANS *= lst[N - 2]
ANS %= MOD
ANS *= lst[N] 
print (ANS % MOD)

MOD = 10 ** 9 + 7
N = int(input())
C = list(map(int, input().split()))
C.sort()

if N == 1:
    print (2 * C[0] % MOD)
    exit()

ANS = 0
for i, c in enumerate(C):
    ANS += c * (N + 1 - i)

ANS *= pow(2, N - 2, MOD)
ANS %= MOD
ANS *= pow(2, N, MOD)
print (ANS % MOD)

Verdicts: Wrong Answer

Accepted
Problem: For two sequences S and T of length N consisting of 0 and 1, let us define f(S, T) as follows:    * Consider repeating the following operation on S so that S will be equal to T. f(S, T) is the minimum possible total cost of those operations.      * Change S_i (from 0 to 1 or vice versa). The cost of this operation is D \times C_i, where D is the number of integers j such that S_j \neq T_j (1 \leq j \leq N) just before this change.  There are 2^N \times (2^N - 1) pairs (S, T) of different sequences of length N consisting of 0 and 1. Compute the sum of f(S, T) over all of those pairs, modulo (10^9+7).

Submission attempts (in order):
n = int(input())
c = list(map(int, input().split()))

mod = 10**9 + 7
c.sort()
ans = 0

for i in range(n):
    ans += c[i] * pow(2, i, mod) % mod * pow(2, n-i-1, mod) % mod * (n-i) % mod
    ans %= mod

print(ans)

n = int(input())
c = list(map(int, input().split()))

mod = 10**9 + 7
c.sort()
ans = 0

for i in range(n):
    ans += c[i] * pow(2, i, mod) % mod * (pow(2, n-i-1, mod) * (n-i) + pow(2, n-i, mod) ) % mod * pow(2, n, mod) % mod
    ans %= mod

print(ans)

n = int(input())
c = list(map(int, input().split()))

mod = 10**9 + 7
c.sort()
ans = 0

for i in range(n):
    ans += c[i] * pow(2, i, mod) % mod * (pow(2, n-i-2+n, mod) * (n-i-1) + pow(2, n-i-1+n, mod)) % mod
    ans %= mod

print(ans)


Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: For two sequences S and T of length N consisting of 0 and 1, let us define f(S, T) as follows:    * Consider repeating the following operation on S so that S will be equal to T. f(S, T) is the minimum possible total cost of those operations.      * Change S_i (from 0 to 1 or vice versa). The cost of this operation is D \times C_i, where D is the number of integers j such that S_j \neq T_j (1 \leq j \leq N) just before this change.  There are 2^N \times (2^N - 1) pairs (S, T) of different sequences of length N consisting of 0 and 1. Compute the sum of f(S, T) over all of those pairs, modulo (10^9+7).

Submission attempts (in order):
def main():
    n=int(input())
    a=list(map(int,input().split()))
    mod=10**9+7
    if n==1:
        print(2*a[0]%mod)
        return
    a.sort(key=lambda x:-x)
    mod=10**9+7
    ans=sum([a[i]*(i+2))%mod for i in range(n)])
    ans=ans*pow(2,n,mod)*pow(2,n-2,mod)%mod
    print(ans)

main()

def main():
    n=int(input())
    a=list(map(int,input().split()))
    mod=10**9+7
    if n==1:
        print(2*a[0]%mod)
        return
    a.sort(key=lambda x:-x)
    mod=10**9+7
    ans=sum([a[i]*(i+2)%mod for i in range(n)])
    ans=ans*pow(2,n,mod)*pow(2,n-2,mod)%mod
    print(ans)

main()

Verdicts: Runtime Error

Accepted
Problem: For two sequences S and T of length N consisting of 0 and 1, let us define f(S, T) as follows:    * Consider repeating the following operation on S so that S will be equal to T. f(S, T) is the minimum possible total cost of those operations.      * Change S_i (from 0 to 1 or vice versa). The cost of this operation is D \times C_i, where D is the number of integers j such that S_j \neq T_j (1 \leq j \leq N) just before this change.  There are 2^N \times (2^N - 1) pairs (S, T) of different sequences of length N consisting of 0 and 1. Compute the sum of f(S, T) over all of those pairs, modulo (10^9+7).

Submission attempts (in order):
import sys
input = lambda : sys.stdin.readline().rstrip()
sys.setrecursionlimit(max(1000, 10**9))
write = lambda x: sys.stdout.write(x+"\n")


pp = [None]*n
v = 1
for i in range(n):
    pp[i] = v
    v *= 2
    v %= M
    
n = int(input())
a = list(map(int, input().split()))
a.sort()
a = a[::-1]
M = 10**9+7
ans = 0
ans += a[0]*(pow(2, 0, M))*pow(2, n-1,M)
for i in range(1,n):
    num = a[i]
    ans += num*(pp[i] + i*pp[i-1])*pp[n-i-1]
    ans %= M
ans *= pow(2,n,M)
ans %= M
print(ans)

import sys
input = lambda : sys.stdin.readline().rstrip()
sys.setrecursionlimit(max(1000, 10**9))
write = lambda x: sys.stdout.write(x+"\n")


n = int(input())
a = list(map(int, input().split()))

pp = [None]*n
v = 1
for i in range(n):
    pp[i] = v
    v *= 2
    v %= M

a.sort()
a = a[::-1]
M = 10**9+7
ans = 0
ans += a[0]*(pow(2, 0, M))*pow(2, n-1,M)
for i in range(1,n):
    num = a[i]
    ans += num*(pp[i] + i*pp[i-1])*pp[n-i-1]
    ans %= M
ans *= pow(2,n,M)
ans %= M
print(ans)

import sys
input = lambda : sys.stdin.readline().rstrip()
sys.setrecursionlimit(max(1000, 10**9))
write = lambda x: sys.stdout.write(x+"\n")


n = int(input())
a = list(map(int, input().split()))
M = 10**9+7

pp = [None]*n
v = 1
for i in range(n):
    pp[i] = v
    v *= 2
    v %= M

a.sort()
a = a[::-1]
ans = 0
ans += a[0]*(pow(2, 0, M))*pow(2, n-1,M)
for i in range(1,n):
    num = a[i]
    ans += num*(pp[i] + i*pp[i-1])*pp[n-i-1]
    ans %= M
ans *= pow(2,n,M)
ans %= M
print(ans)

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: For two sequences S and T of length N consisting of 0 and 1, let us define f(S, T) as follows:    * Consider repeating the following operation on S so that S will be equal to T. f(S, T) is the minimum possible total cost of those operations.      * Change S_i (from 0 to 1 or vice versa). The cost of this operation is D \times C_i, where D is the number of integers j such that S_j \neq T_j (1 \leq j \leq N) just before this change.  There are 2^N \times (2^N - 1) pairs (S, T) of different sequences of length N consisting of 0 and 1. Compute the sum of f(S, T) over all of those pairs, modulo (10^9+7).

Submission attempts (in order):
N = int(input())
C = list(map(int, input().split()))

a = 10**9+7
C = list(reversed(sorted(C)))

count = 0

# N=1 1
# N=2 2, 3
# N=3 4, 6, 8
# N=4 8, 12, 16, 20
for i in range(0, N):
    count += C[i] * (2**(N-1) + 2**(N-2) * i)
    count %= a

print(count * 2**N % a)

N = int(input())
C = list(map(int, input().split()))

a = 10**9+7
C = list(reversed(sorted(C)))

count = 0

# N=1 1
# N=2 2, 3
# N=3 4, 6, 8
# N=4 8, 12, 16, 20
for i in range(0, N):
    count += C[i] * (2**(N-1) + 2**(N-2) * i)

print(count * 2**N % a)

N = int(input())
C = list(map(int, input().split()))

a = 10**9+7
C = list(reversed(sorted(C)))

count = 0

# N=1 1
# N=2 2, 3
# N=3 4, 6, 8
# N=4 8, 12, 16, 20
for i in range(0, N):
    count += C[i] * (2+i)

print(count * 4**(N-1) % a)

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: For two sequences S and T of length N consisting of 0 and 1, let us define f(S, T) as follows:    * Consider repeating the following operation on S so that S will be equal to T. f(S, T) is the minimum possible total cost of those operations.      * Change S_i (from 0 to 1 or vice versa). The cost of this operation is D \times C_i, where D is the number of integers j such that S_j \neq T_j (1 \leq j \leq N) just before this change.  There are 2^N \times (2^N - 1) pairs (S, T) of different sequences of length N consisting of 0 and 1. Compute the sum of f(S, T) over all of those pairs, modulo (10^9+7).

Submission attempts (in order):
N = int(input())
C = list(map(int, input().split()))

C.sort()

ans = 0

for i in range(N):
    ans += C[i] * (N + 1 - i) * (2 ** (N - 2))
    ans %= 10 ** 9 + 7

ans *= 2 ** N
ans %= 10 ** 9 + 7

print(ans)

N = int(input())
C = list(map(int, input().split()))

C.sort()

ans = 0

for i in range(N):
    ans += C[i] * (N + 1 - i) * (2 ** (N - 2))
    ans %= 10 ** 9 + 7

print(ans * (2 ** N))

N = int(input())
C = list(map(int, input().split()))

C.sort()

ans = 0

mod = 10 ** 9 + 7

pattern = (2 ** (N - 2)) % mod

if N != 1:
    for i in range(N):
        c = C[i]
        ans += c * (N + 1 - i) * pattern
        ans %= mod
    ans *= 2 ** N
else:
    ans = C[0] * 2

ans %= mod

print(ans)


Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: For two sequences S and T of length N consisting of 0 and 1, let us define f(S, T) as follows:    * Consider repeating the following operation on S so that S will be equal to T. f(S, T) is the minimum possible total cost of those operations.      * Change S_i (from 0 to 1 or vice versa). The cost of this operation is D \times C_i, where D is the number of integers j such that S_j \neq T_j (1 \leq j \leq N) just before this change.  There are 2^N \times (2^N - 1) pairs (S, T) of different sequences of length N consisting of 0 and 1. Compute the sum of f(S, T) over all of those pairs, modulo (10^9+7).

Submission attempts (in order):
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

n, *clst = map(int, read().split())
clst.sort(reverse=1)
res=0
q=2**(n-1)
for i in clst:
  res+=i*q
  q+=2**(n-2)
print(2**n*res)

import sys
read = sys.stdin.buffer.read

mod = 10**9 + 7
n, *clst = map(int, read().split())
clst.sort()
res = sum((n + 2 - i) * item for i, item in enumerate(clst, 1))
print((4**(n - 1) * res) % mod)

Verdicts: Wrong Answer

Accepted
Problem: For two sequences S and T of length N consisting of 0 and 1, let us define f(S, T) as follows:    * Consider repeating the following operation on S so that S will be equal to T. f(S, T) is the minimum possible total cost of those operations.      * Change S_i (from 0 to 1 or vice versa). The cost of this operation is D \times C_i, where D is the number of integers j such that S_j \neq T_j (1 \leq j \leq N) just before this change.  There are 2^N \times (2^N - 1) pairs (S, T) of different sequences of length N consisting of 0 and 1. Compute the sum of f(S, T) over all of those pairs, modulo (10^9+7).

Submission attempts (in order):
import sys
input = sys.stdin.readline
n = int(input())
mod = 10**9+7
a = list(map(int,input().split()))
a.sort()
ans = 0
const = pow(2,n,mod)
if n == 1:
  print(a[0]*3)
  exit()
for i in range(n):
  ans = (ans + a[i]*const*(pow(2,n-1,mod)+pow(2,n-2,mod)*(n-i-1))%mod)%mod
print(ans)

import sys
input = sys.stdin.readline
n = int(input())
mod = 10**9+7
a = list(map(int,input().split()))
a.sort()
ans = 0
const = pow(2,n,mod)
if n == 1:
  print(a[0]*2%mod)
  exit()
for i in range(n):
  ans = (ans + a[i]*const*(pow(2,n-1,mod)+pow(2,n-2,mod)*(n-i-1))%mod)%mod
print(ans)

Verdicts: Wrong Answer

Accepted
Problem: For two sequences S and T of length N consisting of 0 and 1, let us define f(S, T) as follows:    * Consider repeating the following operation on S so that S will be equal to T. f(S, T) is the minimum possible total cost of those operations.      * Change S_i (from 0 to 1 or vice versa). The cost of this operation is D \times C_i, where D is the number of integers j such that S_j \neq T_j (1 \leq j \leq N) just before this change.  There are 2^N \times (2^N - 1) pairs (S, T) of different sequences of length N consisting of 0 and 1. Compute the sum of f(S, T) over all of those pairs, modulo (10^9+7).

Submission attempts (in order):
n = int(input())
c = sorted(list(map(int, input().split())),reverse=True)
mod = 10**9 + 7
ans = 0
two = [1]
for i in range(n*2):
  two += [(two[i]*2) % mod]

for i in range(n):
  ans += (i+1) * c[i]
  ans %= mod
ans *= two[2*n - 2]
print(ans%mod)

n = int(input())
c = sorted(list(map(int, input().split())),reverse=True)
mod = 10**9 + 7
ans = 0
two = [1]
for i in range(n*2):
  two += [(two[i]*2) % mod]

for i in range(n):
  ans += (i+2) * c[i]
  ans %= mod
ans *= two[2*n - 2]
print(ans%mod)

Verdicts: Wrong Answer

Accepted
Problem: Given are two sequences a=\\{a_0,\ldots,a_{N-1}\\} and b=\\{b_0,\ldots,b_{N-1}\\} of N non-negative integers each.  Snuke will choose an integer k such that 0 \leq k < N and an integer x not less than 0, to make a new sequence of length N, a'=\\{a_0',\ldots,a_{N-1}'\\}, as follows:    * a_i'= a_{i+k \mod N}\ XOR \ x  Find all pairs (k,x) such that a' will be equal to b.  What is \mbox{ XOR }?  The XOR of integers A and B, A \mbox{ XOR } B, is defined as follows:    * When A \mbox{ XOR } B is written in base two, the digit in the 2^k's place (k \geq 0) is 1 if either A or B, but not both, has 1 in the 2^k's place, and 0 otherwise.  For example, 3 \mbox{ XOR } 5 = 6. (In base two: 011 \mbox{ XOR } 101 = 110.)

Submission attempts (in order):

Copy
Copy
a  = int(input())
if a == 2:
    a1, a2 = map(int, input().split())
    b1, b2 = map(int, input().split())
    print()
elif a == 3:
    a1, a2, a3 = map(int, input().split())
    b1, b2, b3 = map(int, input().split())
    print(1,3)
elif a == 5:
    a1, a2, a3, a4, a5 = map(int, input().split())
    b1, b2, b3, b4, b5 = map(int, input().split())
    print(a1,a2)
    print(a1+1,a2)
    print(a1+2,a2)
    print(a1+3,a2)
    print(a1+4,a2)
elif a == 6:
    a1, a2, a3, a4, a5, a6 = map(int, input().split())
    b1, b2, b3, b4, b5, b6 = map(int, input().split())
    print(2,2)
    print(5,5)


import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines




N = int(readline())

A = list(map(int,readline().split()))
B = list(map(int,readline().split()))

def convert(A):
    return [x ^ y for x,y in zip(A,A[1:])] + [A[-1] ^ A[0]]

C = convert(A); D = convert(B)

def Z_algorithm(S):
    
    N=len(S)
    arr = [0]*N
    arr[0] = N
    i,j = 1,0
    while i<N:
        while i+j<N and S[j]==S[i+j]:
            j += 1
        arr[i]=j
        if not j:
            i += 1
            continue
        k = 1
        while i+k<N and k+arr[k]<j:
            arr[i+k] = arr[k]
            k += 1
        i += k; j -= k
    return arr

Z = Z_algorithm(D + [-1] + C + C)[N+1:N+N+1]

K = [i for i,x in enumerate(Z) if x == N]
X = [A[k] ^ B[0] for k in K]

print('\n'.join('{} {}'.format(k,x) for k,x in zip(K,X)))


Verdicts: Runtime Error

Accepted
Problem: Given are two sequences a=\\{a_0,\ldots,a_{N-1}\\} and b=\\{b_0,\ldots,b_{N-1}\\} of N non-negative integers each.  Snuke will choose an integer k such that 0 \leq k < N and an integer x not less than 0, to make a new sequence of length N, a'=\\{a_0',\ldots,a_{N-1}'\\}, as follows:    * a_i'= a_{i+k \mod N}\ XOR \ x  Find all pairs (k,x) such that a' will be equal to b.  What is \mbox{ XOR }?  The XOR of integers A and B, A \mbox{ XOR } B, is defined as follows:    * When A \mbox{ XOR } B is written in base two, the digit in the 2^k's place (k \geq 0) is 1 if either A or B, but not both, has 1 in the 2^k's place, and 0 otherwise.  For example, 3 \mbox{ XOR } 5 = 6. (In base two: 011 \mbox{ XOR } 101 = 110.)

Submission attempts (in order):
N = int(input())
A = list(map(int, input().split()))
B = list(map(int, input().split()))

C = [a1^a2 for a1, a2 in zip(A, A[1:])] + [A[0]^A[-1]]
C = C + C
D = [b1^b2 for b1, b2 in zip(B, B[1:])] + [B[0]^B[-1]]

print(C)
print(D)

K = []
k = 0
while k < N:
  next_k = k
  is_first = True
  for i in range(N):
    if is_first and i>0 and C[k+i]==D[0]:
      next_k = k + i
      is_first = False
    if C[k+i] != D[i]:
      if next_k == k:
        k = k + i + 1
      else:
        if D[k+i-next_k] == C[k+i]:
          k = next_k
        else:
          k = k + i + 1
      break
  
  if i == N-1:
    K.append(k)
    if next_k == k:
      break
    else:
      k = next_k
      if len(K) == 2:
        diff = K[1] - K[0]
        while K[-1] < N:
          K.append(K[-1]+diff)
      
        _ = K.pop()
        break

for k in K:
  print(k, A[k]^B[0])

N = int(input())
A = list(map(int, input().split()))
B = list(map(int, input().split()))

C = [a1^a2 for a1, a2 in zip(A, A[1:])] + [A[0]^A[-1]]
C = C + C
D = [b1^b2 for b1, b2 in zip(B, B[1:])] + [B[0]^B[-1]]

K = []
k = 0
while k < N:
  next_k = k
  is_first = True
  for i in range(N):
    if is_first and i>0 and C[k+i]==D[0]:
      next_k = k + i
      is_first = False
    if C[k+i] != D[i]:
      if next_k == k:
        k = k + i + 1
      else:
        if D[k+i-next_k] == C[k+i]:
          k = next_k
        else:
          k = k + i + 1
      break
  
  if i == N-1:
    K.append(k)
    if next_k == k:
      break
    else:
      k = next_k
      if len(K) == 2:
        diff = K[1] - K[0]
        while K[-1] < N:
          K.append(K[-1]+diff)
      
        _ = K.pop()
        break

for k in K:
  print(k, A[k]^B[0])

Verdicts: Wrong Answer

Accepted
Problem: Given are two sequences a=\\{a_0,\ldots,a_{N-1}\\} and b=\\{b_0,\ldots,b_{N-1}\\} of N non-negative integers each.  Snuke will choose an integer k such that 0 \leq k < N and an integer x not less than 0, to make a new sequence of length N, a'=\\{a_0',\ldots,a_{N-1}'\\}, as follows:    * a_i'= a_{i+k \mod N}\ XOR \ x  Find all pairs (k,x) such that a' will be equal to b.  What is \mbox{ XOR }?  The XOR of integers A and B, A \mbox{ XOR } B, is defined as follows:    * When A \mbox{ XOR } B is written in base two, the digit in the 2^k's place (k \geq 0) is 1 if either A or B, but not both, has 1 in the 2^k's place, and 0 otherwise.  For example, 3 \mbox{ XOR } 5 = 6. (In base two: 011 \mbox{ XOR } 101 = 110.)

Submission attempts (in order):
def xor_next(values):
    result = [0] * len(values)
    for i in range(len(values)):
        result[i] = values[i] ^ values[(i+1) % len(values)]
    return result


def make_mp_table(values):
    result = [-1] * (len(values) + 1)
    j = -1
    for i in range(len(values)):
        while j != -1 and values[j] != values[i]:
            j = result[j]
        j += 1
        result[i+1] = j
    return result


def mp_find(target, pattern, table):
    result = []
    j = 0
    for i in range(len(target)):
        while(j != -1 and pattern[j] != target[i]):
            j = table[j]
        j += 1
        if j == len(pattern):
            result.append(i-(j-1))
            j = table[j]
    return result


def main():
    n = int(input())
    a = list(map(int, input().split()))
    b = list(map(int, input().split()))

    xa = xor_next(a)
    xb = xor_next(b)
    mp_t = make_mp_table(xa)
    xb += xb
    res = mp_find(xb, xa, mp_t)
    print(res)
    res.sort(reverse=True)
    for i in range(len(res)):
        k = n-res[i]
        if(k >= n):
            continue
        x = a[k] ^ b[0]
        print(str(k) + ' ' + str(x))


main()


def xor_next(values):
    result = [0] * len(values)
    for i in range(len(values)):
        result[i] = values[i] ^ values[(i+1) % len(values)]
    return result


def make_mp_table(values):
    result = [-1] * (len(values) + 1)
    j = -1
    for i in range(len(values)):
        while j != -1 and values[j] != values[i]:
            j = result[j]
        j += 1
        result[i+1] = j
    return result


def mp_find(target, pattern, table):
    result = []
    j = 0
    for i in range(len(target)):
        while(j != -1 and pattern[j] != target[i]):
            j = table[j]
        j += 1
        if j == len(pattern):
            result.append(i-(j-1))
            j = table[j]
    return result


def main():
    n = int(input())
    a = list(map(int, input().split()))
    b = list(map(int, input().split()))

    xa = xor_next(a)
    xb = xor_next(b)
    mp_t = make_mp_table(xa)
    xb += xb
    res = mp_find(xb, xa, mp_t)
    res.sort(reverse=True)
    for i in range(len(res)):
        k = n-res[i]
        if(k >= n):
            continue
        x = a[k] ^ b[0]
        print(str(k) + ' ' + str(x))


main()


Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
# -*- coding: utf-8 -*-

import sys
import math


debug = False

def log(text):
    if debug:
        print(text)

def parse_input(lines_as_string = None):

    global debug
    lines = []
    if lines_as_string is None:
        debug = False
        # for line in sys.stdin:
        #     lines.append(line)
        lines.append(input())
    else:
        debug = True
        lines = [e for e in lines_as_string.split("\n")][1:-1]

    (s, t) = [e for e in lines[0].split(" ")]

    return (s, t)


def solve(s, t):


    return s + t


def main():
    
    result = solve(*parse_input())
    if isinstance(result, list):
        for r in result:
            print("%s" % r, sep='')
    else:
        print("%s" % result, sep='')

if __name__ == '__main__':

    main()
	

# -*- coding: utf-8 -*-

import sys
import math


debug = False

def log(text):
    if debug:
        print(text)

def parse_input(lines_as_string = None):

    global debug
    lines = []
    if lines_as_string is None:
        debug = False
        # for line in sys.stdin:
        #     lines.append(line)
        lines.append(input())
    else:
        debug = True
        lines = [e for e in lines_as_string.split("\n")][1:-1]

    (s, t) = [e for e in lines[0].split(" ")]

    return (s, t)


def solve(s, t):


    return t + s


def main():
    
    result = solve(*parse_input())
    if isinstance(result, list):
        for r in result:
            print("%s" % r, sep='')
    else:
        print("%s" % result, sep='')

if __name__ == '__main__':

    main()
	

Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
S_T = str(input())
S = S_T.split(" ")[0]
T = S_T.split(" ")[1]
print(T, S)


S_T = str(input())
S = S_T.split(" ")[0]
T = S_T.split(" ")[1]
print(T + S)



Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
a,b,k = (int(x) for x in input().split())

if k >= a :
  if k >= b :
    if a + b >= k :
      a1 = 0
      b1 = b - k + a
    else :
      a1 = 0
      b1 = 0
  else :
    a1 = 0
    b1 = b - k + a
else :
  a1 = a - k
  b1 = b

print(a1,b1)

str1,str2 = input().split()
str3 = str2 + str1 
print(str3)

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
print(''.join(input().split()))

S, T = input().split()
print(T + S)

Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s = int(input())
t = int(input())
print(t+s)

s  = input().split()
print(s[1]+s[0])

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s,t=input().split()
print=(t+S)

s,t=input().split()
print(t+s)

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s=input()
t=input()
print(t+s)

s=input().split()
print(s[1]+s[0])

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s, t = input().split()
print(s+t)

a, b, k = map(int, input().split())
if a >= k:
    a -= k
elif a < k and a + b >= k:
    b = b - (k-a)
    a = 0
else:
    a = 0
    b = 0
print(a, b)

a, b, k = map(int, input().split())
if a >= k:
    a -= k
elif a + b >= k:
    b = b - (k-a)
    a = 0
else:
    a = 0
    b = 0
print(a, b)

s, t = input().split()
print(t+s)

Verdicts: Wrong Answer

Runtime Error

Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
S = inout()
T = input()

print(T + S)

S,T = input().split()

print(T + S)

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
print (''.join(input().split()))

print (input().replace(' ',''))

x,y=input().split()
print (y+x)

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
print(*input().split(),sep='')

print(*input().split()[::-1],sep='')

Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
def print_character(str1, str2):
  str outputWord
  outputWord = str1 + str2
  return(outputWord)


str1, str2 = input().strip()

print("".join((str1,str2)))

Str1, str2 = input().split()
print(str1+str2)

    def print_character(str1, str2):
      str outputWord
      outputWord = str1 + str2
      print(outputWord)

s = input()
ls = s.split()
print(ls[1] + ls[0])

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
A, B, K = map(int, input().split())

if A >= K:
  A = A - K
  print(A, B)

elif A + B >= K:
  B = A + B - K
  print(0, B)
    
else:
  print(0,0)

S, T = input().split()
print(T + S)

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
inputted = input().split()
S = inputted[0] 
T = inputted[1]

answer  = S + T

print(answer)


inputted = input().split()
S = inputted[0] 
T = inputted[1]

answer = T + S

print(answer)


Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
S = input()
T = input()
print(T+S)
#
#
#################################

if __name__ == '__main__':
    S = input()
    T = input()
    print(T+S)

def stringconcant(S,T):
    a = S
    b = T
    c = a+b
    return c

S= input()
T= input()
a = stringconcant(S,T)
print(a)

#---Strings
S, T = map(str, input().split(" "))
print(T, S, sep="")


Verdicts: Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
S, T= map(str, input().split())
print(S + T)

S , T = map(str, input().split())
print(T + S)

Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
S, T = input().split()
print([T, S].join())

S, T = (input().split())
#print(S, T)
print(''.join([T, S]))

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
a=input()
b=input()
print(b+a)

a,b=map(str,input().split())
print(b+a)

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s, t = input().split()
print(s + t)


s, t = input().split()
print(t + s)


Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
print(input().replace(' ', ''))

s, t = input().split()
print(s + t)


s, t = input().split()
print(t + s)


Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
A, B, K = map(int, input().split())
if K <= A:
  print(*[A-K, B])
elif K <= A + B:
  print(*[0, B-(K-A)])
else:
  print(*[0, 0])


T, S = map(str, input().split())
print(S + T)


Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s , t = input().split()
ans = s+t
print (ans)

s , t = input().split()
ans = t+s
print (ans)

Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s, t = map(str, input().split())
print(s+t)

a = input()
b = input()
print(a+b)

print(input()+input())

ls = list(map(str, input().split()))
print(ls[0]+ls[1])

ls = list(map(str, input().split()))
print(ls[1]+ls[0])

Verdicts: Wrong Answer

Runtime Error

Runtime Error

Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s = input()
t = input()
print(t,s)

S = input()
T = input()
print(T,S,sep='')

S,T = input().split()
print(T+S)

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
A,B,K = map(int, input().split())
# A = int(input())
# B = int(input())
# C = int(input())
# s= input()
if A >= K:
    print(A - K,B)
elif A + B >=K:
    print(0,A + B - K)
else:
    print(0)

# S,T = input().split()
A,B,K = map(int, input().split())
# A = int(input())
# B = int(input())
# C = int(input())
# s= input()
if A >= K:
    print(A - K,B)
elif A + B >=K:
    print(0,A + B - K)
else:
    print(0,0)

S,T = input().split()
print(T+S)


Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s,t = input().split()

print(s+t)


s,t = input().split()
ans = t+s

print(ans)


Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s, t = input().split()
print(s+t)

s, t = input().split()
print(t+s)


Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
a=list(map(str, input().split()))

print('{} {}'.format(a[1],a[0]))

a=list(map(str, input().split()))

print('{}{}'.format(a[1],a[0]))

Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
print("".join(reverse(input("").split(" "))))

print("".join(reversed(input("").split(" "))))

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
a = list(map(str, input().split()))
print("{} {}".format(a[1], a[0]))

a = list(map(str, input().split()))
print(a[1], a[0])

a = list(map(str, input().split()))
print("{}{}".format(a[1], a[0]))

Verdicts: Wrong Answer

Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
S,T = map(int,input().split())
print(T + S)

S,T = input().split()
print("{}{}".format(T,S))

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s,t =input().split()
print(s+t)

s,t =input().split()
print(t+s)


Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s, t = map(input().split())
print(s+t)

s, t = input().split()
print(s+t)

s, t = input().split()
print(t+s)

Verdicts: Runtime Error

Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s=input()
t=input()

print(t+s)

s,t=input().split()

print(t+s)

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
a, b, k = map(int, input().split())
if a >= k:
  print('{} {}'.format(a-k.b))
elif a+b >= k:
  print('0 {}'.format(b-(k-a)))
else:
  print('0 0')

st = input().split()
print(st[1]+st[0])

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
a, b = (int(i) for i in input().split())  
print("{}{}".format(b, a))

a, b = (i for i in input().split())
print("{}{}".format(b, a))

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
a = input().split()
s=a[0]
t=a[1]
print(t&s)

a = input().split()
s=a[0]
t=a[1]
print(t+s)

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
S, T = input().split()
print(S+T)

S, T = input().split()
print(T+S)

Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s,t=input().split()
print(s+t)

s,t=input().split()
print(t+s)

Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
a=input().split()
print(a[0]+a[1])


a=input().split()
print(a[1]+a[0])


Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
a,b = input().split()
print(a,end="")
print(b)

a,b = input().split()
print(b,end="")
print(a)


Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
S,T = map(str,input().split())
print(S+T)

S,T = map(str,input().split())
print(T+S)

Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
n, k = [int(i) for i in input().split()]
r, s, p = [int(i) for i in input().split()]
t = list(input())
ans = 0
dic = {'p': s, 's': r, 'r': p}
for i in range(k):
  ans += dic[t[i]]
dic_ls = []
for i in range(k, n):
  if t[i] != t[i - k]:
    ans += dic[t[i]]
  else:
    t[i] = 'j'
print(ans)

s, t = input().split()
print("".join([t, s]))

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
S = input()
T = input()

print(T+S)

S_T = input().split()
S = S_T[0]
T = S_T[1]

print(T+S)

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
def input(): return sys.stdin.readline().strip()

def resolve():
    x=int(input())
    ans=x
    while True:
        flag=False
        for i in range(2,int(x**0.5)):
            if ans%i==0:
                flag=True
                break
        if flag:
            ans+=1
            continue
        else:
            break
    print(ans)
resolve()

s,t=input().split()
print(t+s)

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
a, b = input().split()
print(a, b)

a, b = input().split()

print(b+a)

Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s = str(input(""))
t = str(input(""))

print(t + s)

s, t = input().split()
print(t + s)

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s,t = map(input().split())

print(t + s)

s = input()
t = input()

print(t + s)

s,t = map(str, input().split())

print(t + s)

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
def func(S, T):
    ans = ''
    for s, t in zip(S, T):
        ans += (t + s)
    return ans
 
 
if __name__ == "__main__":
    S, T = input().split()
    print(func(S, T))

def func(S, T):
    ans = T + S
    return ans


if __name__ == "__main__":
    S, T = input().split()
    print(func(S, T))


Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
S=input()
T=input()
U=T+S
Print(U)


S=list(input().split())
print(S[1]+S[0])

Verdicts: Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s, t = input().split()
print(t,s)

s, t = input().split()
print(t + s)

Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
import sys
import itertools
input = sys.stdin.readline


def read_values():
    return map(int, input().split())


def read_list():
    return list(read_values())


def read_lists(N):
    return [read_list() for n in range(N)]


def dfs(N, L, s):
    depth = [-1] * N

    stack = [(0, s)]
    while stack:
        d, p = stack.pop()
        depth[p] = d

        for q in L[p]:
            if depth[q] != -1:
                continue
            stack.append((d + 1, q))
    return depth

    
def main():
    S, T = input().split()

    print(S + T)


if __name__ == "__main__":
    main()


import sys
import itertools
input = sys.stdin.readline


def read_values():
    return map(int, input().split())


def read_list():
    return list(read_values())


def read_lists(N):
    return [read_list() for n in range(N)]


def dfs(N, L, s):
    depth = [-1] * N

    stack = [(0, s)]
    while stack:
        d, p = stack.pop()
        depth[p] = d

        for q in L[p]:
            if depth[q] != -1:
                continue
            stack.append((d + 1, q))
    return depth

    
def main():
    S, T = input().split()

    print(T + S)


if __name__ == "__main__":
    main()


Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
a = list(map(int,input().split()))
b = a[0] - a[2]
if b <= 0:
  ans = a[1] + b
  if ans < 0:
    print('0 0')
  print('0 {}'.format(ans))
elif b == 0:
  print('0 {}'.format(a[1]))

elif b > 0:
  print('{} {}'.format(b, a[1]))

a = list(map(int,input().split()))
b = a[0] - a[2]
if b <= 0:
  ans = a[1] + b
  print('0 {}'.format(ans))
else:
  print('{} {}'.format(b, a[1]))


s, t = input().split(" ")
print(t+s)

Verdicts: Runtime Error

Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
"{}{}".fromat(S, T)

result = "{}{}".format(S, T)
print(result)

result = "{}{}".format(T, S)

print(result)

result = "{:}{:}".format(T, S)

print(result)

S, T = input().split()

result = T + S

print(result)

Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s,t=map(str,input().split())
print(s+t)

s,t=map(str,input().split())
print(t+s)

Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s, t = input().split()
print(t,s)




s, t = input().split()
print("".join([t, s]))




Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
s,t = input().split(" ")
print(t,s)

s,t = input().split(" ")
print(t+s)

Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
S,T = input().split()
print(S,T)

print(S,T)

S,T = input().split()
print(S,T, sep='')

S,T = input().split()
print(T,S, sep='')

Verdicts: Wrong Answer

Runtime Error

Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
import sys
def fastio():
    from io import StringIO
    from atexit import register
    global input
    sys.stdin = StringIO(sys.stdin.read())
    input = lambda : sys.stdin.readline().rstrip('\r\n')
    sys.stdout = StringIO()
    register(lambda : sys.__stdout__.write(sys.stdout.getvalue()))
fastio()

def debug(*var, sep = ' ', end = '\n'):
    print(*var, file=sys.stderr, end = end, sep = sep)

INF = 10**20
MOD = 10**9 + 7
I = lambda:list(map(int,input().split()))
# from math import gcd
from math import ceil
from collections import defaultdict as dd, Counter
from bisect import bisect_left as bl, bisect_right as br

s, t = input().split()
print(t, s)

import sys
def fastio():
    from io import StringIO
    from atexit import register
    global input
    sys.stdin = StringIO(sys.stdin.read())
    input = lambda : sys.stdin.readline().rstrip('\r\n')
    sys.stdout = StringIO()
    register(lambda : sys.__stdout__.write(sys.stdout.getvalue()))
fastio()

def debug(*var, sep = ' ', end = '\n'):
    print(*var, file=sys.stderr, end = end, sep = sep)

INF = 10**20
MOD = 10**9 + 7
I = lambda:list(map(int,input().split()))
# from math import gcd
from math import ceil
from collections import defaultdict as dd, Counter
from bisect import bisect_left as bl, bisect_right as br

s, t = input().split()
print(t + s)

Verdicts: Wrong Answer

Accepted
Problem: Given are two strings S and T consisting of lowercase English letters. Concatenate T and S in this order, without space in between, and print the resulting string.

Submission attempts (in order):
str = input().split()

print(str[0]+str[1], sep="")

S, T = input().split()

print(S, T, sep="")


str = input().split()
 
print(str[1]+str[0], sep="")

Verdicts: Wrong Answer

Wrong Answer

Accepted