Problem:


Score : 100 points

Problem Statement

Print the K-th element of the following sequence of length 32:

1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51

Constraints

1 \leq K \leq 32

All values in input are integers.

Input

Input is given from Standard Input in the following format:

K

Output

Print the K-th element.

Sample Input 1

6

Sample Output 1

2

The 6-th element is 2.

Sample Input 2

27

Sample Output 2

5

The 27-th element is 5.



Sample input:
6


Sample output:
2

Submission status: Runtime Error

Solution code:
def main():
    a = input()
    b = input()
    c = input()
    A, B, C = len(a), len(b), len(c)
    ab = [True]*10000
    ac = [True]*10000
    bc = [True]*10000

    def check(c1, c2):
        if c1 == '?' or c2 == '?' or c1 == c2:
            return False
        return True

    for i in range(A):
        for j in range(B):
            if check(a[i], b[j]):
                ab[i-j+5000] = False
    for i in range(A):
        for j in range(C):
            if check(a[i], c[j]):
                ac[i-j+5000] = False
    for i in range(B):
        for j in range(C):
            if check(b[i], c[j]):
                bc[i-j+5000] = False
    ans = A + B + C
    for i in range(-(B+C), A+C):
        for j in range(-(B+C), A+B):
            if ab[i+5000] and ac[j+5000] and bc[j-i+5000]:
                L = min(0, i, j)
                R = max(A, i+B, j+C)
                ans = min(ans, R - L)
    print(ans)


main()

Submission status: Runtime Error

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

if (c-a-b) < 0:
    print("No")
else:
    if (a*(a-b-c)+b*(b-a-c)+c*(c-a-b) > 0):
        print("Yes")    
    else:
        print("No")

Submission status: Runtime Error

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

# 答えの出力

if (a**2 + b**2) + (2*(a*b)) < c**2:
    ans = 'Yes'
else:
    ans = 'No'

# 出力
print(ans)

Submission status: Runtime Error

Solution code:
a,b,c=map(int,input().split())
n=c-a-b
if n**2 > 4*a*b:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
a,b,c=map(int,input().split())
if c-a-b>0:
  if 4*a*b<(c-a-b)**2:
  	print('Yes')
  else:
  	print('No')
else:
  print('No')

Submission status: Runtime Error

Solution code:
a,b,c=map(int,input().split())
n=c-a-b
if　n**2 > 4*a*b:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
from math import ceil
h, w = map(int, input().split())

if h == 1 or w == 1:
    print(0)
    exit()
if w % 2 == 0:
    ans = (w // 2) * h
else:
    ans = (w // 2) * h + (ceil(h / 2))
print(ans)

Submission status: Runtime Error

Solution code:
s = input().split()
W = int(s[0])
H = int(s[1])

k = 0
if W % 2 == 0:
    out = (H * W) / 2
else:
    if W % 2 == 0:
        k = H / 2
    else:
        k = H / 2+1
    out = int((H * (W - 1)) / 2) + int(k)

print(int(out))

Submission status: Runtime Error

Solution code:
s = input().split()
W = int(s[0])
H = int(s[1])

if W % 2 == 0:
    out = (H * W) / 2
else:
    if W % 2 == 0:
        k = H / 2
    else:
        k = H / 2+1
    out = int((H * (W - 1)) / 2) + int(k)

print(int(out))

Submission status: Runtime Error

Solution code:
a = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14,
     1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]

num = int(input())
print(a[num])

Submission status: Runtime Error

Solution code:
k = int(input())
li = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
print(li(k-1))

Submission status: Runtime Error

Solution code:
num = input()
num = int(num)

a = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14,
     1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]

print(a[num])

Submission status: Runtime Error

Solution code:
container = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
unser = int(input())
print(container[unser])

Submission status: Runtime Error

Solution code:
import math
a, b, c = map(int, input().split())
ab = a * b
num = ((c-a-b)/2)**2
if ab < num:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
import math
a, b, c = map(int, input().split())
ab = a * b
num = ((c-a-b)/2**2)
if ab < num:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
a,b,c = map(int, input().split())
if ((((c-a-b)**2) > (4*a*b)) & (c-a-b > 0)):
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
import numpy as np
a,b,c = map(int,input().split())
if np.sqrt(c) - np.sqrt(a) - np.sqrt(b) > 0:
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
h,w=map(int,input().split())
if h==1 and w==1:
  print(1)
else:
  if (h*w)%2==1:
    print(int(int(h*w//2)+1))
  else:
    print(int(h*w/2))

Submission status: Runtime Error

Solution code:
a=map(int,"1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51".split())
b=int(input())
print(a[b-1])

Submission status: Runtime Error

Solution code:
# coding: utf-8

num_array = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]

print("{}".format(num_array[k-1]))

Submission status: Runtime Error

Solution code:
#スペース区切りの整数の入力
A, B, C = map(int, input().split())

A = float(A)
B = float(B)
C = float(C)


A_sq = pow(A, 0.5)
B_sq = pow(B, 0.5)
C_sq = pow(C, 0.5)

if(A_sq+B_sq < C_sq):
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
a, b, c = map(int, input().split())
 
if 4*a*b < (c-a-b):
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
import math
a,b,c = list(map(int,input().split()))
if c-a-b>0 and 4*a*b<(c-a-b)^2:
  print("Yes")
else:print("No")

Submission status: Runtime Error

Solution code:
if __name__ == '__main__':
    l = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
    k = int(input())
    print(l[k + 1])

Submission status: Runtime Error

Solution code:
import sys
import re

l = sys.stdin.readline()
l = int(l)
out = []
def x(stri,l,depth):
  str = 'abcdefghij'
  for i in range(0,l-depth+1):
    cdepth = depth
    cstri = stri
    cstri += str[i] 
    cdepth -= 1
    if( cdepth == 0):
	out.append(cstri)
    else:
	x(cstri,l,cdepth)


stri = 'a'
if( l == 1):
 print stri
 exit(0)
x(stri,l,l-1)

ret = {}
count = 0
for i in out:
  prev = '0'
  moji = ""
  uniq = ""
  for j in i:
    if( prev == j ):
      moji += "E"
    else:
      if( j not in uniq ):
        uniq += j
      if( prev > j ):
        moji += "U"
      else:
        moji += "D"
    prev = j
  moji += str(len(uniq))
  if( moji not in ret.values()):
    print i
  ret[count] = moji
  count += 1

sys.stdout.flush()

Submission status: Runtime Error

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

if c-a-b>0 and 4*a*b<(c-a-b)^2:
  print("Yes")
else:print("No")

Submission status: Runtime Error

Solution code:
h,w = map(int,input().split())
if (h*w)%2 == 0:
  print((h*w)//2)
else:
  print((h*w)//2+1)

Submission status: Runtime Error

Solution code:
import math
abc = input()
abc = abc.split(' ')
a = int(abc[0])
b = int(abc[1])
c = int(abc[2])

if (c-a-b>0) and 4*a*b<(c-a-b)*(c-a-b):
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
H,W = map(int,input().split())
 
if (H == 1)or(W == 1):
    sum = 1
elif H % 2 == 0:
    sum = W * H / 2
elif W % 2 == 0:
    sum = (W * (H-1) / 2) + (W / 2)
else:
    sum = (W * (H-1) / 2) + ((W+1) / 2)
 
print(int(sum))

Submission status: Runtime Error

Solution code:
a = [input(),input(),input()]
def checkEqual(l,r,k):
    i = len(l)-k
    j = 0
    for a in range(k):
        x, y = i+a, j+a
        if l[x] != r[y]:
            if l[x]=='?' or r[y]=='?':
                continue
            return False
    return True

overLaps = [[[] for i in range(3)] for j in range(3)]
ij = [(0,1),(1,0),(1,2),(2,1),(0,2),(2,0)]
for i,j in ij:
    l = a[i]
    r = a[j]
    m = min(len(l),len(r))
    for k in range(m+1):
        if checkEqual(l,r,k):
            overLaps[i][j].append(k)

maxRe = 0
combs = [(0,1,2),(0,2,1),(1,0,2),(1,2,0),(2,0,1),(2,1,0)]
for x,y,z in combs:
    full = len(a[y])
    o1 = overLaps[x][y]
    o2 = overLaps[y][z]
    midOl = set(overLaps[x][z])
    for i in range(len(o1)-1,-1,-1):
        for j in range(len(o2)-1,-1,-1):
            re = o1[i] + o2[j]
            if re > full:
                if re-full not in midOl:
                    continue
            maxRe = max(re,maxRe)
    # i = len(o1)-1
    # j = len(o2)-1
    # if o1[i] + o2[j] <= full:
    #     re = o1[i] + o2[j]
    #     maxRe = max(re,maxRe)
    #     continue
    #
    # bar = full - o1[i]
    # while o2[j] > bar:
    #     j -= 1
    #     if j == 0:
    #         break
    # while j < len(o2):
    #     bar = full - o2[j]
    #     while o1[i] > bar:
    #         i -= 1
    #         if i<0:
    #             break
    #     if i<0:
    #         break
    #     re = o1[i] + o2[j]
    #     maxRe = max(re,maxRe)
    #     j += 1

ans = len(a[0])+len(a[1])+len(a[2])-maxRe
print(ans)

Submission status: Runtime Error

Solution code:
import math
a, b,c = map(float, input().split())
if c - a - b > 0 or 4*a*b < (c - a - b)**2:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
a,b,c=map(int,input().split())
if 4*a*b<(c-a-b)**2 and c-a-b>0:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
n = int(input())
l = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
print(l[n+1])

Submission status: Runtime Error

Solution code:
parseInt(x::String) = parse(Int, x)
parseInt(x::SubString{String}) = parse(Int, x)
parseInt(x::Char) = parse(Int, x)
parseInt(x::Float64) = trunc(Int, x)
parseFloat(x::String) = parse(Float64, x)
parseFloat(x::Int) = trunc(Float64, x)
parseMap(x::Array{SubString{String},1}) = map(parseInt, x)

function main()
    arr=[1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
    println(arr[parseInt(readline())])
end
main()

Submission status: Runtime Error

Solution code:
import math
abc = input()
abc = abc.split(' ')
a = int(abc[0])
b = int(abc[1])
c = int(abc[2])

if 4*a*b<(c-a-b)*(c-a-b):
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
import math
abc = input()
abc = abc.split(' ')
a = int(abc[0])
b = int(abc[1])
c = int(abc[2])

if 4*a*b<(c-a-b)*(c-a-b):
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
print([1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51][int(input()-1)]

Submission status: Runtime Error

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

Submission status: Runtime Error

Solution code:
if h == 1 or w ==1:
	print(1)
	exit()
elif w % 2 == 0:
	print(h * w // 2)
	exit()
elif w % 2 == 1:
	if h % 2 == 0:
		print(h * w // 2)
		exit()
	elif h % 2 == 1:
		print((h * w // 2) + 1)
		exit()

Submission status: Runtime Error

Solution code:
h, w = map(int, input().split())
boad = h * w
if w == 1 and h == 1:
  print(1)
else:
  print((boad + 1) // 2)

Submission status: Runtime Error

Solution code:
h , w = map(int, input().split())
c = 0
if h == 1 or w ==1:
	print(1)
	exit()
 
if w % 2 == 0:
	print(h * w // 2)
	exit()
elif w % 2 == 1:
	if h % 2 == 0:
		print(h * w // 2)
		exit()
	elif h % 2 == 1:
		print((h * w // 2) + 1)
		exit()

Submission status: Runtime Error

Solution code:
#B
H,W = map(int, input().split())
s=H*W
if ((H==1) or (W==1)):
    ans = 1
elif (s%2) ==0:
    ans = (s//2)
else:
    ans = ((s+1)//2)
print(ans)

Submission status: Runtime Error

Solution code:
position = int(input())

print(array)

Submission status: Runtime Error

Solution code:
import math
from decimal import Decimal

a, b, c = map(int, input().split())
a = Decimal(a)
b = Decimal(b)
c = Decimal(c)
if (a.sqrt() + b.sqrt() < c.sqrt()):
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
H,W=map(int,input().split())
M = H * W
M2 = M // 2
modm = M % 2
if modm == 0:
    print(M2)
else:
    print(M2 + 1)

Submission status: Runtime Error

Solution code:
import math

a,b,c = map(int,input().split())
if a + b + c == 10 and a == b:
  print("Yes")
if math.sqrt(a * b) < (c - a - b) / 2:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:


def get_str(st, i, len_val):
    ret = '?'*len_val
    for s in st:
        ret[i] = s
        i += 1
    return ret

def main():
    a = input()
    b = input()
    c = input()


    total_len = 6001

    def f(a1, b1, c1):
        nonlocal total_len
        for A,B,C in zip(a1,b1,c1):
            if len(set([char for char in [A,B,C] if char != '?'])) > 1:
                return False
        while a1[-1] != '?':
            a1 = a1[:-1]
        if len(a1) < total_len:
            total_len = len(a1)
        return True

    a_temp = get_str(a,0,len(a)+len(b)+len(c))

    for i in range(len(a)+len(b)+len(c)):
        try:
            b_temp = get_str(b,i,len(a)+len(b)+len(c))
            for j in range(len(a)+len(b)+len(c)):
                try:
                    c_temp = get_str(c,j,len(a)+len(b)+len(c))

                except:
                    pass
        except:
            pass

if __name__ == '__main__':
    main()

Submission status: Runtime Error

Solution code:
# -*- coding: utf-8 -*-
from decimal import *

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

a = Decimal(a)
b = Decimal(b)
c = Decimal(c)

if a**(1/2) + b**(1/2) < c**(1/2):
    print("Yes")

else:
    print("No")

Submission status: Runtime Error

Solution code:
l=[]
s = "1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51"
s = s.replace(' ','')
l = s.split(',')
k = input()
print(l[int(k)])

Submission status: Runtime Error

Solution code:
K = input()
data = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
print(data[K - 1])

Submission status: Runtime Error

Solution code:
def main():
    a,b,c = map(int,input().split())
    if (a ** (1/2)+b **(1/2) - c **(1/2)) > 1e-12:
        print("Yes")
    else:
        print("No")


if __name__ == "__main__":
    main()

Submission status: Runtime Error

Solution code:
a=input()
a_l=len(a)
b=input()
b_l=len(b)
c=input()
c_l=len(c)
def check(s1,s2):
    l1=len(s1)
    l2=len(s2)
    ret=[0]*(l1+l2-1)
    for i in range(l1+l2-1):
        flag=True
        if i-l2+1<0:
            for j in range(i+1):
                if s1[j]!="?" and s2[l2-i+j-1]!="?" and s1[j]!=s2[l2-i+j-1]:
                    flag=False
                    break
        elif i-l2+1>=0 and i<=l1-1:
            for j in range(l2):
                if s1[i-l2+j+1]!="?" and s2[j]!="?" and s1[i-l2+j+1]!=s2[j]:
                    flag=False
                    break
        else:
            for j in range(l1+l2-i-1):
                if s1[i-l2+j+1]!="?" and s2[j]!="?" and s1[i-l2+j+1]!=s2[j]:
                    flag=False
                    break
        ret[i]=flag
    return ret
ab=check(a,b)
ab_l=len(ab)
ac=check(a,c)
ac_l=len(ac)
bc=check(b,c)
bc_l=len(bc)
ans=a_l+b_l+c_l
for i in range(-3000,ab_l+3000):
    if i<0 or i>=ab_l or ab[i]:
        for j in range(-3000,ac_l+3000):
            if j<0 or j>=ac_l or ac[j]:
                if (0<=j-i+b_l+1<bc_l and bc[j-i+b_l+1]) or j-i+b_l+1<0 or j-i+b_l+1>=bc_l:
                    l=max(a_l-1,i,j)-min(0,i-b_l+1,j-c_l+1)+1
                    ans=min(ans,l)
print(ans)

Submission status: Runtime Error

Solution code:
h, w = map(int, input().split())
a=int(h/2)+1
b=h/2
c=0


for j in range(w):
        if j%2==1:
            c=c+a
        else:
            c=c+b
    





print(c)

Submission status: Runtime Error

Solution code:
lis = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
 
k = int(input())
 
print(lis[k])

Submission status: Runtime Error

Solution code:
from math import sqrt as r
a, b, c = map(int, input().split())
n = r(a) + r(b)
if (a + b + 2 * r(a * b)) * a * b < a * b * c:
    print("Yes")
else:
    print("No")
#print(n)
#print(r(c))

Submission status: Runtime Error

Solution code:
chars = ['a','b','c','d','e','f','g','h','i','j']
length = int(input())
def cals(words, num, length):
  work = words
  for val in range(0, length):
    temp = work + chars[val]
    if num + 1 == length:
      print(temp)
    else:
      cals(temp, num + 1, length)
      break
cals('',0 , length)

Submission status: Runtime Error

Solution code:
import math as np
a,b,c=map(int, input().split())
r=(1-((a**2/c**2)+(b**2/c**2)))**2
if r>4*a*b:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
import math
a,b,c = map(int,input().split())
if c*c - (a + b + 2*math.sqrt(a*b))**2>0:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
arr = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
n = input()
print(arr[int(n)+1])

Submission status: Runtime Error

Solution code:
from decimal import *
getcontext().prec = 100
a, b, c = map(int, input().split())
if Decimal(str((c - a - b) ** 2)) - Decimal(str(4 * a * b)) > 0:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
import decimal

a, b, c = map(int, input().split())
a = decimal.Decimal(a)
b = decimal.Decimal(b)
b = decimal.Decimal(b)

if 4*a*b - (c-a-b)**2 < 0:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:

ab=""
cnt = 0
while ab=="" and cnt<len(a):
  for i in range(min(len(b),len(a)-cnt)):
    if a[i+cnt]!="?" and b[i]!="?" and a[i+cnt]!=b[i]:
      ab=""
      break
    else:
      if a[i+cnt]!="?":
        ab += a[i+cnt]
      else:
        ab +=b[i]
if ab=="":
  ab =a+b
abc=""
cnt=0
while abc=="" and cnt<len(ab):
  for i in range(min(len(c),len(ab)-cnt)):
    if ab[i+cnt]!="?" and c[i+cnt]!="?" and ab[i+cnt]!=c[i+cnt]:
      abc=""
      break
    else:
      if ab[i+cnt]!="?":
        abc+=ab[i+cnt]
      else:
        abc+=c[i]
if abc!="":
  ans =min(ans,len(abc))

Submission status: Runtime Error

Solution code:
arr = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
n = input()
print(arr[int(n)])

Submission status: Runtime Error

Solution code:
import math

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

if (2*a*b < c**2 + a**2 + b**2 - 2*a*c - 2*b*c):
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
[a,b,c]=[int(inp) for inp in input().split()]
#if a*a+b*b+c*c -2*(a*b+b*c+c*a) > 0:
if a*(a-2*b)+b*(b-2*c)>-c*(c-2*a):
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
s =[1, 1, 1, 2, 1, 
   2, 1, 5, 2, 2,
   1, 5,
   1, 2, 1, 14, 1, 5, 1, 5, 
   2, 2, 1, 15, 2, 2, 5,
   4, 1, 4, 1, 51]
k = input（"plase input position k to get a value, 0<=k<=32\n"）
k = int(k)
if (k<=32)and(k>=0):
 print(s[k-1:k])
else:
 print("plase input a vaild value\n")

Submission status: Runtime Error

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

x = math.sqrt(a)
y = math.sqrt(b)
z = math.sqrt(c)

x += y

if x < z:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:

l = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
# 各条件の入力
i = int(input())
# 答えの出力
print(l[i])

Submission status: Runtime Error

Solution code:
import math
a, b, c = map(int, input().split())
a_sqrt = math.sqrt(a)
b_sqrt = math.sqrt(b)
c_sqrt = math.sqrt(c)

if (a==c) or (b==c):
	print('No')

elif (a_sqrt+b_sqrt) < c_sqrt:
	print('Yes')

else:
	print('No')

Submission status: Runtime Error

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

if h % 2 == 0:
    ans = h / 2 * w
elif w % 2 == 0:
    ans = (h - 1) / 2 * w / 2 + (h + 1) / 2 * w / 2
else:
    ans = (h - 1) / 2 * (w - 1) / 2 + (h + 1) / 2 * (w + 1) / 2

if h == 1 or w == 1:
    ans = 1

print(int(ans))

Submission status: Runtime Error

Solution code:
s =[1, 1, 1, 2, 1, 
   2, 1, 5, 2, 2,
   1, 5,
   1, 2, 1, 14, 1, 5, 1, 5, 
   2, 2, 1, 15, 2, 2, 5,
   4, 1, 4, 1, 51]
k = input（"plase input position k to get a value, 0<=k<=32\n"）
if (k<=32)and(k>=0):
 print(s[k-1, k])
else:
  print("plase input a vaild value\n")

Submission status: Runtime Error

Solution code:
H = input()
W = input()
mas = int(H)*int(W)
h = mas%2

if h==0:
    print(int(mas/2))
else:
    print(int((mas+1)/2))

Submission status: Runtime Error

Solution code:
lis = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]

k = int(input())

print(lis[k+1])

Submission status: Runtime Error

Solution code:
list = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
K = int(input())
if K < 32:
    print(list[K+1])
else:
    print(list[33])

Submission status: Runtime Error

Solution code:
#include <bits/stdc++.h>
#define rep(i, a) for (int i = 0; i < (a); ++i)
#define REP(i, a, b) for (int i = (a); i < (b); ++i)
#define pb push_back
typedef long long ll;
typedef long double la;
using namespace std;
 
int main(){
    ll h,w,a=0;
    cin >> h >> w;
    if(h%2 == 0){
        h = (h/2)*w;
        a = h;
    }else{
        h = h/2+1;
        rep(i,w){
           if(i%2 == 0){
               a += h;
           }else{
               a += (h-1);
           } 
        }  
    }
    cout << a << endl;
    return 0;
}

Submission status: Runtime Error

Solution code:
import math
a,b,c=map(int, input().split())
if (a/c) ** 2+(b/c)**2+2* math.sqrt(a*b/(c ** 2))<1:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
in_list = list(map(int,input().split()))
a = in_list[0]
b = in_list[1]
c = in_list[2]
if 0 < (c*c - 2*a*b + a*a - 2*b*c + b*b - 2*c*a):
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
import math

firstInputText = input()
inputList = firstInputText.split()
a = int(inputList[0])
b = int(inputList[1])
c = int(inputList[2])
x = math.sqrt(a) + math.sqrt(b)
y = math.sqrt(c)
# print(x)
# print(y)

# if math.isclose(x,y):
#     print("Yes")
# else:
#     print("No")
if x == y:
    print("No")
elif x < y:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
import math
import numpy

min = 0.00000000000000000000001
attemptLimits = 250000
a , b , c = map(int,input().split())

# 解を求める関数
def targetFunc(x,y):
    return x**2 - y
 
# 導関数
def derivative(x):
    return 2.0*x      
 
def newtonMethod(a, min,y):
    for i in range(attemptLimits):
        # 漸化式
        ah = a - targetFunc(a,y)/derivative(a)
        
        # 収束条件
        if abs(a - ah) < min:break
        
        # 近似解の更新
        a = ah
    return a

a = newtonMethod(a,min,a)
b = newtonMethod(a,min,b)
c = newtonMethod(a,min,c)

if a + b  < c:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
list = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
a = int(input())
print(list[a+1])

Submission status: Runtime Error

Solution code:
ls = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
num = input()
k = int(num) + 1
print(ls[k])

Submission status: Runtime Error

Solution code:
lists = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
user_input = eval(input())
print(lists[user_input])

Submission status: Runtime Error

Solution code:
#include <iostream>
#include <vector>
int main(){
int vec1;
  
  std::vector<int> vec1{ 1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51};
cin >> K >> endl;
  cout << vec1.at(K-1) << endl;


}

Submission status: Runtime Error

Solution code:
import math

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

if (4*a*b < (a + b - c)**2):
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
ls = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
num = input()
print(ls[int(num)+1])

Submission status: Runtime Error

Solution code:
N = int(input())
alp = ["b","c","d","e","f","g","h","i","j","a"]
a = "a"
A = "a"
for i in range(N):
    word = [a]
    a = a + "a"
for i in range(N):
    word = [A]
    A = A + alp.pop(0)
word.pop(0)
word.sort()
s = "\n".join(word)
print(s)

Submission status: Runtime Error

Solution code:
import sys
sys.setrecursionlimit(1000000)
input = sys.stdin.readline
from bisect import *
from collections import *
from heapq import *
INF = 500000
mod = 10**9+7

a, b, c = map(int, input().split())
if a*a+b*b+c*c > 2*(a*b+b*c+c*a) and c > 4:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
import math
 
datas = input().split(" ")
 
a = float(datas[0])
b = float(datas[1])
c = float(datas[2])
 
if(a+b < (c-a-b)**2):
  print( "Yes" )
else:
  print( "No" )

Submission status: Runtime Error

Solution code:
import math

a,b,c = input().split()

left = int(a) + int(b)
right = int(c)

a = math.sqrt(int(a))
b = math.sqrt(int(b))
#c = math.sqrt(int(c))

left = left + 2*a*b


ans = ""

if(left< right):
    ans = "Yes"
else:
    ans = "No"

print(ans)

Submission status: Runtime Error

Solution code:
h, w = map(int, input().split())
hei = int(h / 2) if h % 2 == 0 else (int(h / 2) + 1)
wid = int(h / 2) if h % 2 == 0 else int((h - 1) / 2)
res = int(w / 2) * (hei + wid) if w % 2 == 0 else (int(w / 2) * (hei + wid)) + hei
print(res)

Submission status: Runtime Error

Solution code:
a, b, c = map(int, input().split())
num = c**2+a**2+b**2-2*a*c+2*a*b-2*b*c
if bin(num) <= bin(4*a*b):
  print("No")
else:
  print("Yes")

Submission status: Runtime Error

Solution code:
from sympy import *

Submission status: Runtime Error

Solution code:
K = int(input())
list = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
kou = list[K+1])
print(K+1,"番目の項は", kou, "です。")

Submission status: Runtime Error

Solution code:
import math
a ,b ,c = map(int,input().split())
ra = (math.sqrt(a))
rb = (math.sqrt(b))
rc = (math.sqrt(c))
if ra + rb < rc:
    print("Yes")
elif ra + rb >= rc:
    print("No")
else:
    print("No")

Submission status: Runtime Error

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

if 4*a*b < (c-a-b)*(c-a-b):
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
ls = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
num = scan()
print(ls[int(num)])

Submission status: Runtime Error

Solution code:
import math
import decimal
decimal.getcontext().prec = 6
a, b, c = map(int, input().split())
a = decimal.Decimal(a)
b = decimal.Decimal(b)
c = decimal.Decimal(c)
d = decimal.Decimal(math.sqrt(a*b))
if a + 2 * d +b - c < 1e-20:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
list = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
K=input()
print([K-1])

Submission status: Runtime Error

Solution code:
K = int(input())
list = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
print(list[K])

Submission status: Runtime Error

Solution code:
import math
a, b, c = map(int, input().split())
a_sqrt = math.sqrt(a)
b_sqrt = math.sqrt(b)
c_sqrt = math.sqrt(c)

if (a+b) > c:
	print('No')

if (a_sqrt+b_sqrt) < c_sqrt:
	print('Yes')
else:
	print('No')

Submission status: Runtime Error

Solution code:
from decimal import *
import math
h=input().split()
a,b,c=int(h[0]),int(h[1]),int(h[2])
e=Decimal(math.sqrt(a))
f=Decimal(math.sqrt(b))
g=Decimal(math.sqrt(c))
if(e+f==g):
  print('No')
elif(e+f>g):
  print('No')
else:
  print('Yes')

Submission status: Runtime Error

Solution code:
def main():
    a,b,c = list(map(int,input().split(' ')))
    #a,b,c = list(map(lambda x:abs(int(x)),input().split(' ')))
    # if (a**0.5 + b**0.5) < (c**0.5):
    #     print('Yes')
    # else:
    #     print('No')

    if c < 0:
        print('No')
        return
    if (4*a*b) < ((c-a-b)**2):
        print('Yes')
    else:
        print('No')

if __name__ == '__main__':
    main()

Submission status: Runtime Error

Solution code:
list = [1, 1, 1, 2, 1, 2, 1, 5, 2, 2, 1, 5, 1, 2, 1, 14, 1, 5, 1, 5, 2, 2, 1, 15, 2, 2, 5, 4, 1, 4, 1, 51]
print([K-1])

Submission status: Runtime Error

Solution code:
a, b, c = map(int, input().split())
if a + b >= c:
    print('No')
elif a**0.5+b**0.5-c**0.5 < 1e-50:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
def main():
    a,b,c = list(map(int,input().split(' ')))
    #a,b,c = list(map(lambda x:abs(int(x)),input().split(' ')))
    # if (a**0.5 + b**0.5) < (c**0.5):
    #     print('Yes')
    # else:
    #     print('No')

    if (4*a*b) < ((c-a-b)**2) and c>=0:
        print('Yes')
    else:
        print('No')

if __name__ == '__main__':
    main()

Submission status: Runtime Error

Solution code:
from decimal import Decimal
from math import sqrt
a,b,c=map(int,input().split())
if Decimal(sqrt(a))+Decimal(sqrt(b))<Decimal(sqrt(c)):
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
from decimal import *

getcontext().prec = 10000
a, b, c = map(int, input().split())

l = Decimal(a).sqrt() + Decimal(b).sqrt()
r = Decimal(c).sqrt()

if l < r:
    print("Yes")
else:
    print("No")

Submission status: Runtime Error

Solution code:
H, W = [int(i) for i in input().split()]

if H==1 or W==1:
    print(1)
    quit()
if H%2==0:
    H //= 2
    print(H*W)
elif W%2==0:
    W //= 2
    print(H*W)
else:
    W -= 1
    c = (W//2)*H
    c += H//2 + 1
    print(c)

Submission status: Runtime Error

Solution code:
from decimal import *

getcontext().prec = 1000000000
a,b,c =map(int,input().split())
d=math.sqrt(a)
e=math.sqrt(b)
f=math.sqrt(c)
h= d+e
if h<f:
  print('Yes')
else:
  print('No')

Submission status: Runtime Error

Solution code:
import numpy as np
a,b,c=map(int, input().split())
if np.sqrt(a)+np.sqrt(b)<np.sqrt(c):
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
import math
import decimal

num = decimal.Decimal(0)
a, b, c = map(int, input().split())
#a = decimal.Decimal(a)
#b = decimal.Decimal(b)
#c = decimal.Decimal(c)
ab =  decimal.Decimal(a) + decimal.Decimal(b) + decimal.Decimal(2 * (math.sqrt(a*b)))
#num = a + b + ab
if ab < c:
  print("Yes")
else:
  print("No")

Submission status: Runtime Error

Solution code:
a, b, c = map(int, input().split())
if a + b >= c:
    print('No')
elif a**0.5+b**0.5-c**0.5 < 1e-30:
    print('Yes')
else:
    print('No')

Submission status: Runtime Error

Solution code:
import math
import numpy

min = 0.0000000000000001
attemptLimits = 100000
a , b , c = map(int,input().split())

# 解を求める関数
def targetFunc(x,y):
    return x**2 - y
 
# 導関数
def derivative(x):
    return 2.0*x      
 
def newtonMethod(a, min,y):
    for i in range(attemptLimits):
        # 漸化式
        ah = a - targetFunc(a,y)/derivative(a)
        
        # 収束条件
        if abs(a - ah) < min:break
        
        # 近似解の更新
        a = ah
    return a

a = newtonMethod(a,min,a)
b = newtonMethod(a,min,b)
c = newtonMethod(a,min,c)

if a + b  < c:
    print("Yes")
else:
    print("No")