Problem:


Score : 100 points

Problem Statement

We have three boxes A, B, and C, each of which contains an integer.

Currently, the boxes A, B, and C contain the integers X, Y, and Z, respectively.

We will now do the operations below in order. Find the content of each box afterward.  

Swap the contents of the boxes A and B

Swap the contents of the boxes A and C

Constraints

1 \leq X,Y,Z \leq 100

All values in input are integers.

Input

Input is given from Standard Input in the following format:

X Y Z

Output

Print the integers contained in the boxes A, B, and C, in this order, with space in between.

Sample Input 1

1 2 3

Sample Output 1

3 1 2

After the contents of the boxes A and B are swapped, A, B, and C contain 2, 1, and 3, respectively.

Then, after the contents of A and C are swapped, A, B, and C contain 3, 1, and 2, respectively.  

Sample Input 2

100 100 100

Sample Output 2

100 100 100

Sample Input 3

41 59 31

Sample Output 3

31 41 59



Sample input:
1 2 3


Sample output:
3 1 2

Submission status: Runtime Error

Solution code:
n,p = map(int,input().split(" "))
 
l = input().split(" ")
s = 0
for  i in l:
  m = int(i)
  s = s + m
 
t = s/4*p
 
c = 0
for i in l:
  m = int(i)
  if m >= t:
    c = c + 1
if c >= p:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
list1 = list(map(int, input().split()))
list2= []
list2[0] = list1[2]
list2[1] = list1[0]
list2[2] = list1[1]
print(list2)

Submission status: Runtime Error

Solution code:
a  = []
input = a[]
print( a[2],a[0],a[1])

Submission status: Runtime Error

Solution code:
a,b,c = map(int, input().split())
a,b,c = c,a,b
print(f"{a} {b} {c}")

Submission status: Runtime Error

Solution code:
import sys
import os
import bisect, collections, copy, itertools, math, string
def I(): return int(input())
def S(): return input()
def LI(): return list(map(int, input().split()))
def LS(): return list(input().split())



def solve():
	ABC = LI()
    
    def swap(i, j):
      tmp = ABC[i]
      ABC[i] = ABC[j]
      ABC[j] = tmp
      
    swap(0, 1)
    swap(0, 2)
    print(ABC[0], ABC[1], ABC[2])
    
    
	
if __name__ == '__main__':
	solve()

Submission status: Runtime Error

Solution code:
X, Y, Z = [int(input()) for a in range(3)]
print(Z, X, Y)

Submission status: Runtime Error

Solution code:
A B C=map(int,input().split())
print(C,A,B)

Submission status: Runtime Error

Solution code:
n,m=map(int,input().split())
A = list(map(int,input().split()))
s=sum(A)
c=0
for a in A:
    if a >= s/(4*m):
        c=c+1

if c>=m:
     print('Yes')
else:
    print("No")

Submission status: Runtime Error

Solution code:
X, Y, Z = [int(a) for b in input() .split()]
print(Z, X, Y)

Submission status: Runtime Error

Solution code:
X = int(input())
Y = int(input())
Z = int(input())
print(Z, X, Y)

Submission status: Runtime Error

Solution code:
X = int(input())
Y = int(input())
Z = int(input())

print(Z, X, Y)

Submission status: Runtime Error

Solution code:
X, Y, Z = input()
print(Z, X, Y)

Submission status: Runtime Error

Solution code:
X,Y,Z = input()
print(Z,X,Y)

Submission status: Runtime Error

Solution code:
a = int(input())
b = int(input())
c = int(input())
print(c,a,b)

Submission status: Runtime Error

Solution code:
X = int(input())
Y = int(input())
Z = int(input())

print(Z,X,Y)

Submission status: Runtime Error

Solution code:
a,b,c=int(input())

print(c,a,b)

Submission status: Runtime Error

Solution code:
#include <bits/stdc++.h>

using namespace std;
typedef long long ll;

#define INF (long long)(1e9+7)
#define REP(i,n) for(ll i = 0; i < n; i++)
#define REP1(i,n) for(ll i = 1; i <= n; i++)

int main(void)
{
  int a,b,c;
  cin >>a >> b >> c;
  swap(a, b);
  swap(a, c);
  cout << a << " " << b << " " << c << endl;
}

Submission status: Runtime Error

Solution code:
N, M = map(int, input().split())
A = list(map(int, input().split()))
vote = sum(A)
#print(vote)
count = 0
line = 4*M
line2 = vote/line
ans = "No"

for i in A:
    if (i >= line2):
        count += 1

#print(count)
if (count > M):
    ans = "Yes"


print(ans)

Submission status: Runtime Error

Solution code:
X,Y,Z = map(int,input().split())
print(Z X Y)

Submission status: Runtime Error

Solution code:
x,y,z=(map(int,input().split())

print("{} {}".format(z,x,y))

Submission status: Runtime Error

Solution code:
x,y,z=(map(int,input().split())

print(z, x, y)

Submission status: Runtime Error

Solution code:
x,y,z=(map(int,input().split())

print(z,x,y)

Submission status: Runtime Error

Solution code:
X=str(input([0]))
Y=str(input([1]))
Z=str(input([2]))
print(X,Y,Z)

Submission status: Runtime Error

Solution code:
X=str(input([0]))
Y=str(input([1]))
Z=str(input([2]))
print([2] [0] [1])

Submission status: Runtime Error

Solution code:
A, B, C = [int(i) for i in input().split()]

A, B, C = B, A, C
A, B, C = C, B, A

print(f"{A} {B} {C}")

Submission status: Runtime Error

Solution code:
def swap(A,B):
    a = A
    A = B
    B = a
    return A,B
X,Y,Z = map(int,input().split())
X,Y = swap(X,Y)
X,Z = swap(X,Z)
print(f'{X} {Y} {Z}')

Submission status: Runtime Error

Solution code:
x,y,z=map(int,input().split())
def sort(a,b):
    tmp=a
    a=b
    b=tmp
sort(x,y)
sort(x,z)
print(f"{z} {x} {y}")

Submission status: Runtime Error

Solution code:
x,y,z=map(int,input().split())
print(f"{z} {x} {y}")

Submission status: Runtime Error

Solution code:
n,k = map(int,input().split())
count = 0
lst =[n]
if n > k:
  while n > k :
    n -= k
    count += 1
    lst.append(n)
  opponent = abs(lst[count] - k)  
  if lst[count] >= opponent:
    print(opponent)
  else:
    print(lst[count])
else:
  op = abs(n-k)
  if n >= op:
    print(op)
  else:
    print(n)

Submission status: Runtime Error

Solution code:
X,Y,Z=map(int,input().split())
print(Y Z X)

Submission status: Runtime Error

Solution code:
X,Y,Z=map(int,inpput().split())
print(str(Z)+" "+str(Y)+" "+str(X))

Submission status: Runtime Error

Solution code:
X, Y, X = map(str, input().split())
print(Z, X, Y)

Submission status: Runtime Error

Solution code:
# B - Popular Vote
# https://atcoder.jp/contests/abc161/tasks/abc161_bß

# N 商品の種類数
# M 選択したい商品数
# votes 各商品ごとの投票数
N,M = list(map(int,input().split()))
votes = list(map(int,input().split()))

# 総投票数
total_vote = 0

# 総投票数算出
for vote in votes:
    total_vote += vote

# 購入できる商品数
i = 0

for vote in votes:
    # 得票数が総投票数の 1/4M 以上であれば商品を選択
    if vote >= total_vote*(1/(4*M)):
        i += 1

# 商品をM個購入できる場合
if i >= M:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
a,b,c = list(map(int, input(),split()))
print(c,a,b)

Submission status: Runtime Error

Solution code:
a = list(map(str, input(),split()))
print(a[2],a[0],a[1])

Submission status: Runtime Error

Solution code:
a = list(map(int, input(),split()))
print(a[2],a[0],a[1])

Submission status: Runtime Error

Solution code:
a=int(input())

print(a[1])

Submission status: Runtime Error

Solution code:
#abc 161c
import math
n,k = map(int, input().split())
i = int(n/k)
ilow = i
iup = i+1
print(min(n,abs(n-k*iup),n-k*ilow))

Submission status: Runtime Error

Solution code:
x,y,z=map(int,(input.split())
print(str(y)+" "+str(z)+" "+str(x))

Submission status: Runtime Error

Solution code:
x,y,z=map(int, input.split())
print(str(y)+" "+str(z)+" "+str(x))

Submission status: Runtime Error

Solution code:
z,x,c=map(int, input.split())
print(str(x)+" "+str(y)+" "+str(z))

Submission status: Runtime Error

Solution code:
z,x,c=map(int, input.split())
print(str(z)+" "+str(x)+" "+str(y))

Submission status: Runtime Error

Solution code:
a,b,c=map(int, input.split())
print(str(z)+" "+str(x)+" "+str(y))

Submission status: Runtime Error

Solution code:
print(" ".join([map(str,input().split())]))

Submission status: Runtime Error

Solution code:
a,b,c=map(int, input.split())
print(map(str(a b c)))

Submission status: Runtime Error

Solution code:
a,b,c=map(int, input.split())
print(str(a b c))

Submission status: Runtime Error

Solution code:
a,b,c=map(int, input.split())
print(str(z x y))

Submission status: Runtime Error

Solution code:
a,b,c=map(int, input.split())
printstr((z x y))

Submission status: Runtime Error

Solution code:
a,b,c=map(int, input.split())
print(z,x,y)

Submission status: Runtime Error

Solution code:
d,s,r=map(int,input().split())
print(f"{r} {d} {s}")

Submission status: Runtime Error

Solution code:
N, M = map(int, input().split())
A = list(map(int, input().split()))

totalVote = sum(A)
border = totalVote / (4 * M)
A.sort(reverse = True)

if A[M-1] >= border:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
X, Y, Z = map(int, input().split())

x = str(X)
y = str(Y)
z = str(Z)
print(Z + " " + X + " " + Y)

Submission status: Runtime Error

Solution code:
X, Y, Z = map(int, input().split())

print(Z + " " + X + " " + Y)

Submission status: Runtime Error

Solution code:
a,b,c = map(int input().split())
print(c,a,b)

Submission status: Runtime Error

Solution code:
x,y.z=map(int,input().split())
print(z,x,y)

Submission status: Runtime Error

Solution code:
a,b,c=input()

print(c,a,b)

Submission status: Runtime Error

Solution code:
n, k = map(int, input().split())
m = n
while m > 0:
  n = min(abs(n - k), n)
  if m > n:
      m = n
  else:
      print(m)
      break

Submission status: Runtime Error

Solution code:
n, k = map(int, input().split())
m = n
while m > 0:
  n = min(abs(n - k), n)
  if m > n:
      m = n
  else:
      print(n)
      break

Submission status: Runtime Error

Solution code:
n, k = map(int, input().split())
m = n
while m > 0:
  n = min(abs(n - k), m)
  if m > n:
      m = n
  else:
      print(n)
      break

Submission status: Runtime Error

Solution code:
A = list(map(int, input().split()))
print(f"{A[2]} {A[0]} {A[1]}")

Submission status: Runtime Error

Solution code:
from sys import stdin
import fractions

n, m = [int(x) for x in stdin.readline().rstrip().split()]
a_list = [int(x) for x in stdin.readline().rstrip().split()]

pick = [ x for x in a_list if x >= sum(a_list) * fractions.Fraction(1, 4 * m )]

print("Yes" if len(pick) > m else "No")

Submission status: Runtime Error

Solution code:
from sys import stdin

a, b, c = [int(x) for x in stdin.readline().rstrip().split()]

print(f'{c} {a} {b}')

Submission status: Runtime Error

Solution code:
x,y,z = map(int,input().split())
l = []

l[0] = z
l[1] = x
l[2] = y

print(l)

Submission status: Runtime Error

Solution code:
x,y,z = list(map(int,input().split()))
l = []

l[0] = z
l[1] = x
l[2] = y

print(l)

Submission status: Runtime Error

Solution code:
x, y, z = map(int, raw_input().split())
  
print(z+" "+x+" "+y)

Submission status: Runtime Error

Solution code:
a,b,c = map(int,input().split())
print("{}{}{}".format(c,a,b)

Submission status: Runtime Error

Solution code:
n, m = map(int, input().split())
vote = list(map(int, input().split()))

vote.sort(reverse=True)
popular = vote[0:m]
sum = sum(vote)

yes = True
print('sum=', sum, sum/(4*m))
print('list=', popular)

for win in popular:
    if win < sum / (4*m):
        print('No')
        yes = False
        break

print(yes)

if yes:
    print('Yes')

Submission status: Runtime Error

Solution code:
"X,Y,Z"=input().split()
A=Z
B=Y
C=X
print(A,B,C)

Submission status: Runtime Error

Solution code:
X,Y,Z = intput().split()

print(Z,X,Y)

Submission status: Runtime Error

Solution code:
X,Y,Z = map(str,intput().split())

print(Z,X,Y)

Submission status: Runtime Error

Solution code:
A, B, C = input().split()  
print(C A B)

Submission status: Runtime Error

Solution code:
a, b, c = map(int, input().split())

a, b = b, a
a, c = c, a

print(a + " " + b + " " + c)

Submission status: Runtime Error

Solution code:
# input
A, B, C = map(int, input().split())

# change box
tmp = A
A = B
B = tmp

tmp = A
A = C
C = tmp
    

# output
print("{} {} {]".format(A, B, C))

Submission status: Runtime Error

Solution code:
# input
A, B, C = map(int, input().split())

# output
print("{} {} {]".format(C, A, B))

Submission status: Runtime Error

Solution code:
"X,Y,Z"=input().split()
A=Z
B=Y
C=X
print(A B C)

Submission status: Runtime Error

Solution code:
s = [input()]
print(s[2], s[0], s[1])

Submission status: Runtime Error

Solution code:
s = [input(),input(),input()]
print(s[2], s[0], s[1])

Submission status: Runtime Error

Solution code:
s = input()
t = input()
u = input()
print(u, s, t)

Submission status: Runtime Error

Solution code:
s = input()
t = input()
u = inpuy()
print(t, u, s)

Submission status: Runtime Error

Solution code:
s = input()
t = input()
u = input()
print(t u s)

Submission status: Runtime Error

Solution code:
line = input().rstrip().split(" ")
N = [str(n) for n in line]
X = N[0]
Y = N[1]
Z = N[2]
tmp = 0

tmp = X
X = Y
Y = tmp

tmp = X
X = Z
Z = tmp

print(*X,*Y,*Z)

Submission status: Runtime Error

Solution code:
X, Y, Z=int(input().split())
 
print(Z, X, Y)

Submission status: Runtime Error

Solution code:
X,Y,Z=int(input().split())

print(Z,X,Y)

Submission status: Runtime Error

Solution code:
n,k=map(int,input().split())
n=n-(n//k)*k
print(min(n,k-n))

Submission status: Runtime Error

Solution code:
a,b,c = int(input().split())
a,b,c = c,a,b
print(a,b,c)

Submission status: Runtime Error

Solution code:
a,b,c = int(input().split())
aa = b
bb = a
cc = aa
aaa = c
print(aaa, bb, cc)

Submission status: Runtime Error

Solution code:
N,M = list(map(int,input().split()))
L = list(map(int,input().split()))#len(L) == N

p = sum(L)/(4*M)

cnt = 0
for i in range(N):
    if L[i] >= p:
        cnt += 1
if cnt >= M:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
import sys

sys.setrecursionlimit(10 ** 7)
rl = sys.stdin.readline


def solve():
    x, y, z = map(int, rl().sprit())
    print(z, x, y)
    

if __name__ == '__main__':
    solve()

Submission status: Runtime Error

Solution code:
A = 1
B = 2
C = 3
if A == 1:
  A.append(2)
  del A[0]
  print(A)
  B.append(1)
  del B[0]
  print(B)
  A.append(3)
  del A[0]
  print(A)
  C.append(2)
  del C[0]
  print(C)

Submission status: Runtime Error

Solution code:
nums = map(int,input().split())

print(nums[2],nums[0],nums[1])

Submission status: Runtime Error

Solution code:
Z,X,Y =int(input().split())
print(X,Y,Z)

Submission status: Runtime Error

Solution code:
box = [input(),input(),input()]
X,Y,Z = box
print(Y,Z,X)

Submission status: Runtime Error

Solution code:
#!/usr/bin/env python
import sys
from collections import Counter
from itertools import permutations, combinations
#from fractions import gcd
from math import gcd
from math import ceil, floor
import bisect
sys.setrecursionlimit(10 ** 6)
inf = float("inf")

def input():
    return sys.stdin.readline()[:-1]

def main():
    x, y, z = map(int, input().split())
    print(z, x, y) 


if __name__ == '__main__':
    main()

Submission status: Runtime Error

Solution code:
X,Y,Z=map(int,input().split()))

print(Z, X, Y)

Submission status: Runtime Error

Solution code:
X = int(input())
Y = int(input())
Z = int(input())

print(Z, X, Y)

Submission status: Runtime Error

Solution code:
X = input()
Y = input()
Z = input()

print(Z, X ,Y)

Submission status: Runtime Error

Solution code:
X,Y,Z=map(int,input().split())

print(Z,X,Y)X,Y,Z=map(int,input().split())

print(Z,X,Y)

Submission status: Runtime Error

Solution code:
X=int(input())
Y=int(input())
Z=int(input())
print(Z,X,Y)

Submission status: Runtime Error

Solution code:
X=int(input())
Y=int(input())
Z=int(input())
print(Z)
print(X)
print(Y)

Submission status: Runtime Error

Solution code:
n, k = (int(x) for x in input().split())
if n%k == 0:
  print(0)
else:
  i = int(n/k)
  f = n/k - i
  if f<= 0.5:
    print(abs(n - i*k))
  else:
    print(abs(n - (i + 1)*k))

Submission status: Runtime Error

Solution code:
A = list(map(int,input().split()))
print(A[2]+" "+A[0]+" "+A[1])

Submission status: Runtime Error

Solution code:
a,b,c = list(map(int,input().split()))
print(c+" "+a+" "+b)

Submission status: Runtime Error

Solution code:
n, k = (int(x) for x in input().split())
if n%k == 0:
  print(0)
else:
  i = int(n/k)
  f = abs(n/k) - abs(i)
  if f<= 0.5:
    print(abs(n - i*k))
  else:
    print(abs(n - (i + 1)*k))

Submission status: Runtime Error

Solution code:
n, m = map(int, input().split())
l = list(map(int,input().split()))
l = sorted(l)[::-1]
check = l[m - 1] > (sum(l) / 4 / m)
print("Yes" if check else "No")

Submission status: Runtime Error

Solution code:
print(int(input()) int(input()) int(input()))

Submission status: Runtime Error

Solution code:
n, k = (float(x) for x in input().split())
if n%k == 0:
  print(0)
else:
  i = int(n/k)
  f = n/k - i
  if f<= 0.5:
    print(abs(n - i*k))
  else:
    print(abs(n - (i + 1)*k))

Submission status: Runtime Error

Solution code:
print(int(input(Z)) int(input(X)) int(input(Y)))

Submission status: Runtime Error

Solution code:
a=Y
b=X
c=Z
A=c
B=b
C=a
print(A" "B" "C)

Submission status: Runtime Error

Solution code:
n, k = (int(x) for x in input().split())
if n%k == 0:
  print(0)
else:
  i = int(n/k)
  f = n/k - i
  if f<= 0.5:
    print(abs(n - i*k))
  else:
    print(abs(n - (i + 1)*k))

Submission status: Runtime Error

Solution code:
a=Y
b=X
c=Z
A=c
B=b
C=a
print(A B C)

Submission status: Runtime Error

Solution code:
x,y,z = map(input().split())
print(z,x,y)

Submission status: Runtime Error

Solution code:
k = int(input())
a = [1, 2, 3, 4, 5, 6, 7, 8, 9]

for i in range(k):
    if a[i] % 10 != 0:
        a.append(10*a[i] + a[i] % 10 - 1)
    a.append(10*a[i] + a[i] % 10)
    if a[i] % 10 != 9:
        a.append(10*a[i] + a[i] % 10 + 1)

print(a[k - 1])

Submission status: Runtime Error

Solution code:
x,y,z = map(int,input())
print(z,x,y)

Submission status: Runtime Error

Solution code:
N, M = map(int, input().split())
vote_result_list = sorted(list(map(int,input().split())))[::-1]
border = sum(vote_result_list)/(4*M)
print("Yes" if vote_result_list[M-1] >= border else "No")

Submission status: Runtime Error

Solution code:
x, y, z = map(int, input().split())

print(' '.join(z, x, y))

Submission status: Runtime Error

Solution code:
num_list = input()

temp = num_list[1] # temporarily save B
num_list[1] = num_list[0] # put A in B
num_list[0] = temp # put B in A

temp = num_list[0] # temporarily save A
num_list[0] = num_list[2] # put C in A
num_list[2] = temp # put A in C

print(num_list)

Submission status: Runtime Error

Solution code:
n, r = map(int, input().split())
if n >=10:
    print(r)
else:
    print(r + 100*(10-n))

Submission status: Runtime Error

Solution code:
import math

N,K = map(int,input().split())
tmp = N%K

while True:
  if abs(tmp - K) < tmp:
    tmp = abs(tmp - K)
  else:
    break
 	
print(tmp)

Submission status: Runtime Error

Solution code:
import math

N,K = map(int,input().split())
tmp = N

while True:
  if abs(tmp - K) < tmp:
    tmp = abs(tmp - K)
  else:
    break
 	
print(tmp)

Submission status: Runtime Error

Solution code:
import math

N,K = map(int,input().split())
tmp = 0

while True:
	tmp = N
	if abs(tmp - K) < tmp:
		tmp = abs(tmp - K)
	else:
		break
 	
print(tmp)

Submission status: Runtime Error

Solution code:
a,b,c = map(int,input(),split())
print(c,a,b)

Submission status: Runtime Error

Solution code:
X,Y,Z = map(int,input().split)
X,Y = Y,X
X,Z = Z,X
print(X,Y,Z)

Submission status: Runtime Error

Solution code:
X,Y,Z = map(int,input().split)
X,Y,Z = Z,X,Y
print(X,Y,Z)

Submission status: Runtime Error

Solution code:
X = int(input())
Y = int(input())
Z = int(input())
A,B,C = X,Y,Z
A,B,C = C,A,B
print(A,B,C)

Submission status: Runtime Error

Solution code:
X = int(input())
Y = int(input())
Z = int(input())
X,Y,Z = Z,X,Y

Submission status: Runtime Error

Solution code:
X = int(input())
Y = int(input())
Z = int(input())
M = X
X = Y
Y = M
M = X
X = Z
Z = M
print(X,Y,Z)

Submission status: Runtime Error

Solution code:
n, k = map(int, input().split())

mo = n%k

mok = abs(mo - k)

if mo <= mok:
    print(mo)
else:
    print(mok)

Submission status: Runtime Error

Solution code:
a, b ,c = map(input().split(" "))
print(c+" "+a+" "+b)

Submission status: Runtime Error

Solution code:
#!/usr/bin/env python3

import sys
# import math
# import re                                    # re.compile(pattern) => ptn obj; p.search(s), p.match(s), p.finditer(s) => match obj; p.sub(after, s)
# from collections import deque                # deque class. deque(L): dq.append(x), dq.appendleft(x), dq.pop(), dq.popleft(), dq.rotate()
# from collections import defaultdict          # subclass of dict. defaultdict(facroty)
# from collections import Counter              # subclass of dict. Counter(iter): c.elements(), c.most_common(n), c.subtract(iter)
# from heapq import heapify, heappush, heappop # built-in list. heapify(L) changes list in-place to min-heap in O(n), heappush(heapL, x) and heappop(heapL) in O(lgn).
# from heapq import nlargest, nsmallest        # nlargest(n, iter[, key]) returns k-largest-list in O(n+klgn).
# from itertools import count, cycle, repeat   # count(start[,step]), cycle(iter), repeat(elm[,n])
# from itertools import groupby                # [(k, list(g)) for k, g in groupby('000112')] returns [('0',['0','0','0']), ('1',['1','1']), ('2',['2'])]
# from itertools import starmap                # starmap(pow, [[2,5], [3,2]]) returns [32, 9]
# from itertools import product                # product(iter, repeat=n)
# from itertools import accumulate             # accumulate(iter[, f])
# from functools import reduce                 # reduce(f, iter[, init])
# from functools import lru_cache              # @lrucache ...arguments of functions should be able to be keys of dict
# from bisect import bisect_left, bisect_right # bisect_left(a, x, lo=0, hi=len(a)) returns i such that all(val<x for val in a[lo:i]) and all(val>-=x for val in a[i:hi]).
# from copy import deepcopy                    # to copy multi-dimentional matrix without reference


def main():
    mod = 1000000007                  # 10^9+7
    inf = float('inf')
    sys.setrecursionlimit(10**6)    # 1000 -> 1000000
    def input(): return sys.stdin.readline().rstrip()
    def ii():  return int(input())
    def mi():  return map(int, input().split())
    def mi_0(): return map(lambda x: int(x)-1, input().split())
    def lmi(): return list(map(int, input().split()))
    def lmi_0(): return list(map(lambda x: int(x)-1, input().split()))
    def li():  return list(input())
    
    
    a, b, c = mi()
    print(f"{c} {a} {b}")

if __name__ == "__main__":
    main()

Submission status: Runtime Error

Solution code:
a,b,c = int(input())
print(c,a,b)

Submission status: Runtime Error

Solution code:
box = list(map(int,input().split()))
box.reverse()
for x in box:
    print(x,end = " \0")
print("\n",end = "\0"

Submission status: Runtime Error

Solution code:
K = int(input())
num = list(range(1, 10))
for i in range(K):
  a = num[i]
  b = 10 * a + a % 10
  if a % 10 != 0:
    num.append(b - 1)
  num.append(b)
  if a % 10 != 9:
    num.append(b + 1)
print(num[K - 1])

Submission status: Runtime Error

Solution code:
X = int(input())
Y = int(input())
Z = int(input())
X,Y = Y,X
X,Z = Z,X
print(X,Y,Z)

Submission status: Runtime Error

Solution code:
N, M = map(int, input().split())
A = sorted(list(map(int, input().split())))[::-1]
A_sum = sum(A)

count = 0;
criteria = A_sum/(4*M)

print("No") if (A[M - 1] < criteria) else print("Yes")

Submission status: Runtime Error

Solution code:
N,K=map(int,input().split())
t=N%K
print(min(t,K-t))

Submission status: Runtime Error

Solution code:
N,M=map(int,input().split())
a=list(map(int,input().split()))
SUM=sum(a)
ninnki=SUM/(4*M)
count=0

for i in a:
    if i>=ninnki:
        count+=1
        
if count>=M:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
#include<iostream>
using namespace std;

int main()
{
  int a,b,c;
  cin>>a>>b>>c;
  cout<<c<<" "<<a<<" "<<b;
  return 0;
}

Submission status: Runtime Error

Solution code:
a,b,c = int(input().split())
print(c,a,b)

Submission status: Runtime Error

Solution code:
#include<iostream>
using namespace std;

int main()
{
   int a,b,c;
   cin>>a>>b>>c;
   cout<<c<<" "<<a<<" "<<b;
  return 0;
}

Submission status: Runtime Error

Solution code:
#include<iostream>
using namespace std;

int main()
{
  int a,b,c;
  cin>>a>>b>>c;
  int temp;
  temp = a;
  a = b;
  b = temp;
  temp = a;
  a = c;
  c = temp;
  cout<<a<<" "<<b<<" "<<c;
  return 0;
}

Submission status: Runtime Error

Solution code:
a,b,c = int(input().split())
a,b = b,a
a,c = c,a
print(a,b,c)

Submission status: Runtime Error

Solution code:
a = list(int(input().split()))

a[0],a[1] = a[1],a[0]
a[0],a[2] = a[2].a[0]
print(a[0],a[1],a[2])

Submission status: Runtime Error

Solution code:
X = input().split(" ")
print(f"{X[2]} {X[0]} {X[1]}")

Submission status: Runtime Error

Solution code:
# C - Replacing Integer
# https://atcoder.jp/contests/abc161/tasks/abc161_c

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

# while 1 != 0:
#     if N - K >= 0:
#         N = abs(N - K)
#     else:
#         print(N)
#         exit()

# Nの数が大きすぎるとタイムアウトする
# 求める最小値がN/Kの余りかK-(N/K)の余りであることを利用して解く。

# 7%3 -> 1
# 3-(7%3) -> 2

print(min((N%K),K-(N%K)))

Submission status: Runtime Error

Solution code:
# C - Replacing Integer
# https://atcoder.jp/contests/abc161/tasks/abc161_c

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

while 1 != 0:
    if N - K >= 0:
        N = abs(N - K)
    else:
        print(N)
        exit()

Submission status: Runtime Error

Solution code:
# C - Replacing Integer
# https://atcoder.jp/contests/abc161/tasks/abc161_c

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

while 1 != 0:
    if N - K >= 0:
        N = abs(N - K)
    else:
        print((N))
        exit()

Submission status: Runtime Error

Solution code:
k = int(input())
lunlun = list(range(1, 10))

for i in range(k - 1):
    a = lunlun[i]
    b = a * 10 + a % 10
    if a % 10 != 0:
        lunlun.append(b - 1)
    lunlun.append(b)
    if a % 10 != 9:
        lunlun.append(b + 1)
print(lunlun[k - 1])

Submission status: Runtime Error

Solution code:
x, y, z = (int(i) for i in input().split())
a,b = y,x
a,c = c,a
print(a,b,c," ")

Submission status: Runtime Error

Solution code:
line = input().split

X = line[0]
Y = line[1]
Z = line[2]

print( str(Y) + " " + str(X) + " " + str(Z) )

Submission status: Runtime Error

Solution code:
line = input().split

X = line[0]
Y = line[1]
Z = line[2]

print( Z + " " + X + " " + Y )

Submission status: Runtime Error

Solution code:
line = input().split

X = line[0]
Y = line[1]
Z = line[2]

print( Y + " " + X + " " + Z )

Submission status: Runtime Error

Solution code:
number = [a,b,c]
a,b,c = input()
a,b = b,a
a,c = c,a
print(number)

Submission status: Runtime Error

Solution code:
a,b,c = input()
a,b = b,a
a,c = c,a
print(a,b,c)

Submission status: Runtime Error

Solution code:
i = input().split()
i_int = [int(n) for n in i]
a = input().split()
A = [int(m) for m in a]
N = i_int[0]
M = i_int[1]

th = sum(A)/(4 * M)

##print(threshhold)

c = 0
for val in A:
    if val >= th:
    ##print(val)
        c += 1

if M >= c:
    print('No')
else:
    print('Yes')

Submission status: Runtime Error

Solution code:
l = input().split()
l_int = [int(a) for a in l]
N = l_int[0]
K = l_int[1]
 
print(min(N%K, abs(K - (N%K)))

Submission status: Runtime Error

Solution code:
i = input().split()
i_int = [int(n) for n in i]
a = input().split()
A = [int(m) for m in a]
N = i_int[0]
M = i_int[1]

th = int(sum(A)/(4 * M))

##print(threshhold)

c = 0
for val in A:
    if val >= th:
    ##print(val)
        c += 1

if M > c:
    print('No')
else:
    print('Yes')

Submission status: Runtime Error

Solution code:
i = input().split()
i_int = [int(n) for n in i]
a = input().split()
A = [int(m) for m in a]
N = i_int[0]
M = i_int[1]

threshhold = int(sum(A)/(4 * M))

##print(threshhold)

c = 0
for val in A:
    if val > threshhold:
    ##print(val)
        c += 1

if M > c:
    print('No')
else:
    print('Yes')

Submission status: Runtime Error

Solution code:
i = input().split()
i_int = [int(n) for n in i]
a = input().split()
A = [int(m) for m in a]
N = i_int[0]
M = i_int[1]

threshhold = int(sum(A)/(4 * M))

##print(threshhold)

c = 0
for val in A:
    if val > threshhold:
    ##print(val)
        c += 1

if M > c:
  print('No')
else:
  print('Yes')

Submission status: Runtime Error

Solution code:
i = input().split()
i_int = [int(n) for n in i]
a = input().split()
A = [int(m) for m in a]
N = i_int[0]
M = i_int[1]

threshhold = int(sum(A)/(4 * M))

##print(threshhold)

c = 0
for val in A:
    if val > threshhold:
    ##print(val)
    c += 1

if M > c:
    print('No')
else:
    print('Yes')

Submission status: Runtime Error

Solution code:
i = input().split()
i_int = [int(n) for n in i]
a = input().split()
A = [int(m) for m in a]
N = i_int[0]
M = i_int[1]

threshhold = int(sum(A)/(4 * M))

##print(threshhold)

c = 0
for val in A:
  if val > threshhold:
    ##print(val)
    c += 1

if M > c:
  print('No')
else:
  print('Yes')

Submission status: Runtime Error

Solution code:
n , m = map(int,input().split())
arr = list(map(int,input().split()))
add = sum(arr)
miniVotes = int(add*(1/(4*m)))
cnt = 0
for i in range(len(arr)):
	if arr[i]>=miniVotes:
		cnt+=1
if(cnt>=m):
	print("Yes")
else:
	print("No")

Submission status: Runtime Error

Solution code:
x ,y ,z = map(int,intput().split())
print(z,x,y)

Submission status: Runtime Error

Solution code:
x = int(input())
y = int(input())
z = int(input())

a = z
b = x
c = y

print(str(a)+" "+str(b)+" "+str(c))

Submission status: Runtime Error

Solution code:
x = int(input())
y = int(input())
z = int(input())

a = z
b = y
c = x

print("%i %i %i" %(a,b,c))

Submission status: Runtime Error

Solution code:
x = int(input())
y = int(input())
z = int(input())

a = z
b = y
c = x

print("%i %i %i" %(a,b,c))

Submission status: Runtime Error

Solution code:
num1 = int(input()) 
num2 = int(input())
num3=int(input())
print(num3 + " "+ num1 + " "+ num2)

Submission status: Runtime Error

Solution code:
from sys import stdin

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

Submission status: Runtime Error

Solution code:
x,y,z=map(int,imput().split())
print(z,x,y)

Submission status: Runtime Error

Solution code:
x,y,z=map(int,imput().split())
print(z,x,y)

Submission status: Runtime Error

Solution code:
x,y,z=map(int,imput().split())
print(z+' '+x+' '+y)

Submission status: Runtime Error

Solution code:
x,y,z=list(map(int,input(),split()))

print(z,x,y)

Submission status: Runtime Error

Solution code:
x,y,z=list(map(int,input(),splut()))

print(z,x,y)

Submission status: Runtime Error

Solution code:
l = input()
m = input()
z = l.split(' ')
M = int(z[1])
N = int(z[0])
F = m.split(' ')
X = []

for item in F:
  votes = int(item)
  X.append(votes)
print("Yes")

Submission status: Runtime Error

Solution code:
l = input()
m = input()
z = l.split(' ')
M = int(z[1])
N = int(z[0])
C = (1/(4*M))*N
F = m.split(' ')
X = []
print("No")

for item in F:
	votes = int(item)
	X.append(votes)
X.sort(reverse = True)
for i in range(M):
	if X[i]<C:
		print("No")
		return
print("Yes")

Submission status: Runtime Error

Solution code:
in = list(map(int, input().split()))

print(in[2], in[0], in[1])

Submission status: Runtime Error

Solution code:
k = int(input())
lunlun = [0] * 100
lunlun[1] = [1, 2, 3, 4, 5, 6, 7, 8, 9]
i = 1

for i in range(9):
    n = len(lunlun[i])
    lunlun[i+1] = []
    for x in lunlun[i]:
        r = x%10
        if r > 0:
            lunlun[i+1].append(10*x + r-1)
        lunlun[i+1].append(10*x + r)
        if r < 9:
            lunlun[i+1].append(10*x + r+1)
    i += 1

for i in range(1, 11):
    for j in range(len(lunlun[i])):
        k -= 1
        if k == 0:
            print(lunlun[i][j])
            exit()