Problem:


Score : 400 points

Problem Statement

Takahashi has a water bottle with the shape of a rectangular prism whose base is a square of side a~\mathrm{cm} and whose height is b~\mathrm{cm}. (The thickness of the bottle can be ignored.)

We will pour x~\mathrm{cm}^3 of water into the bottle, and gradually tilt the bottle around one of the sides of the base.

When will the water be spilled? More formally, find the maximum angle in which we can tilt the bottle without spilling any water.

Constraints

All values in input are integers.

1 \leq a \leq 100

1 \leq b \leq 100

1 \leq x \leq a^2b

Input

Input is given from Standard Input in the following format:

a b x

Output

Print the maximum angle in which we can tilt the bottle without spilling any water, in degrees.
Your output will be judged as correct when the absolute or relative error from the judge's output is at most 10^{-6}.

Sample Input 1

2 2 4

Sample Output 1

45.0000000000

This bottle has a cubic shape, and it is half-full. The water gets spilled when we tilt the bottle more than 45 degrees.

Sample Input 2

12 21 10

Sample Output 2

89.7834636934

This bottle is almost empty. When the water gets spilled, the bottle is nearly horizontal.

Sample Input 3

3 1 8

Sample Output 3

4.2363947991

This bottle is almost full. When the water gets spilled, the bottle is still nearly vertical.



Sample input:
2 2 4


Sample output:
45.0000000000

Submission status: Accepted

Solution code:
import numpy as np
a,b,x=map(int,input().split())

if x/a>=a*b/2:
  print(np.rad2deg(np.arctan((2*a**2*b-2*x)/a**3)))
else:
  print(np.rad2deg(np.arctan(a*b**2/(2*x))))

Submission status: Accepted

Solution code:
#!/usr/bin/python3

import array
import math
import os
import sys


def main():
    A, B, X = read_ints()
    print(solve(A, B, X))


def solve(A, B, X):
    if A * A * B == X:
        return 0

    xa = X / A
    lb = 0.0
    ub = 90.0
    while ub - lb > 1e-12:
        mid = (ub + lb) / 2
        dprint(mid)
        theta = mid / 180 * math.pi
        dprint(theta)
        tan = math.tan(theta)
        if tan < B / A:
            a = A * B - A * A / 2 * tan
        else:
            a = B * B / 2 / tan
        dprint(a, xa)
        if a > xa:
            lb = mid
        else:
            ub = mid

    return (ub + lb) / 2


###############################################################################
# AUXILIARY FUNCTIONS

DEBUG = 'DEBUG' in os.environ


def inp():
    return sys.stdin.readline().rstrip()


def read_int():
    return int(inp())


def read_ints():
    return [int(e) for e in inp().split()]


def dprint(*value, sep=' ', end='\n'):
    if DEBUG:
        print(*value, sep=sep, end=end)


if __name__ == '__main__':
    main()

Submission status: Accepted

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

area=x/a
limit=a*b/2
if area<limit:
    t=2*area/b
    print(m.degrees(m.atan(b/t)))
else:
    t=2*area/a-b
    print(m.degrees(m.atan((b-t)/a)))

Submission status: Accepted

Solution code:
import math
a, b, x = map(int, input().split())
s = x / a
if s > a * b / 2:
  if x == a * a * b:
    print(0)
  else:
    rad = math.atan(a ** 3 / (2 * a * a * b - 2 * x))
    print(90 - (rad * 180 / math.pi))
else:
  rad = math.atan(a * b * b / (2 * x))
  print(rad * 180 / math.pi)

Submission status: Accepted

Solution code:
def input():
    import sys
    return sys.stdin.readline().rstrip()


def main():
    import math
    import collections
    import itertools

    a, b, x = map(int, input().split())
    y = 2 * x / (a ** 2) - b
    if y >= 0:
        print(math.degrees(math.atan((b - y) / a)))
    else:
        print(math.degrees(math.atan(a * (b ** 2) / (2 * x))))



if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
import math

a, b, x = map(int, input().split())
c = (x * 2) / (a * b)
d = (2 * x) / (a * a) - b
if a * a * b / 2 >= x:
    print(math.degrees(math.atan2(b, c)))
else:
    print(math.degrees(math.atan2(b - d, a)))

Submission status: Accepted

Solution code:
from math import atan,degrees
a,b,x=map(int,input().split())
if a*a*b>x*2:
  aa,bb=(x/(a*b))*2,b
else:
  x=a*a*b-x
  aa,bb=a,(x/(a*a))*2
print(degrees(atan(bb/aa)))

Submission status: Accepted

Solution code:
W, H, X = map(int, input().split())
X /= W
if W*H==X:
    print(0)
    quit()
import math
if H*2*X/pow(H,2)<=W:
    print(90 - math.atan(2*X/pow(H,2)) * 180/math.pi)
else:
    angle = 90 - math.atan(W*W/(2*(W*H-X))) * 180/math.pi
    print(angle)

Submission status: Accepted

Solution code:
from math import atan2, pi
a,b,x = map(int, input().split())

S = a * a * b

if x / S >= 0.5:
    n = 2*(x - S) / (a * a)
    print(abs(atan2(n, a) * 180 / pi))
else:
    n = 2 * x / (a * b)
    print(abs(atan2(b, n) * 180 / pi))

Submission status: Accepted

Solution code:
import math
ii = lambda: int(input())
mis = lambda: map(float,input().split())
lmis = lambda: list(mis())

n = lmis()
a = n[0]
b = n[1]
x = n[2]

m = 2*x/(a**2)-b

if m >= 0:
    print(90-math.degrees(math.atan2(a,b-m)))
else:
    c = a - 2*x/a/b
    print(90-math.degrees(math.atan2(a-c,b)))

Submission status: Accepted

Solution code:
import math

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

pi = math.pi


c = 2 * x / a **2 - b
if c >= 0:
    th = math.asin(a / (math.sqrt(a**2 +(b - (2 * x / a **2 - b))**2)))


else:

    th = math.acos(b/(math.sqrt((2*x / (b*a))**2+b**2)))

deg = math.degrees(th)
print(90-deg)

Submission status: Accepted

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

if x < a*a*b/2:
	print(math.degrees(math.atan(a*b*b/(2*x))))
else:
	print(math.degrees(math.atan((2*a*a*b - 2*x) / (a*a*a))))

Submission status: Accepted

Solution code:
import math

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

if x <= (a * a * b / 2):
    angle = math.atan(a * b * b / (2 * x)) * 180 / math.pi
    print(angle)
else:
    angle = math.atan(2 * (a * a * b - x) / (a * a * a)) * 180 / math.pi
    print(angle)

Submission status: Accepted

Solution code:
import math
a,b,x=map(int,input().split())
 
if a*b//2*a>=x:
  print(90-math.degrees(math.atan(2*x/(a*b*b))))
else:
  if a*b*b==x:
    print(0)
  else:
    print(90-math.degrees(math.atan(a/(2*b-2*x/a/a))))

Submission status: Accepted

Solution code:
import sys
stdin = sys.stdin

sys.setrecursionlimit(10 ** 7)

def li(): return map(int, stdin.readline().split())
def li_(): return map(lambda x: int(x) - 1, stdin.readline().split())
def lf(): return map(float, stdin.readline().split())
def ls(): return stdin.readline().split()
def ns(): return stdin.readline().rstrip()
def lc(): return list(ns())
def ni(): return int(stdin.readline())
def nf(): return float(stdin.readline())

from math import degrees, atan

a, b, x = li()
c = x / (a*a)

if x == a*a*b:
    print(0)
elif a * c > (a * b) / 2:
    print(90 - degrees(atan((a / (2*(b-c))))))
else:
    print(90 - degrees(atan(2*a*c / (b**2))))

Submission status: Accepted

Solution code:
import sys
read = sys.stdin.buffer.read
input = sys.stdin.buffer.readline
inputs= sys.stdin.buffer.readlines
#rstrip().decode('utf-8')

import math
#import numpy as np
#import operator
#from heapq import heapify,heappop,heappush
#from math import gcd
#from fractions import gcd
#from collections import deque
#from collections import defaultdict
#from collections import Counter
#from itertools import accumulate
#from itertools import groupby
#from itertools import permutations
#from itertools import combinations
#from scipy.sparse import csr_matrix
#from scipy.sparse.csgraph import floyd_warshall
#from scipy.sparse.csgraph import csgraph_from_dense
#from scipy.sparse.csgraph import dijkstra
#sys.setrecursionlimit(10**7)

#map(int,input().split())

def main():

	a,b,x=map(int,input().split())
	if 0<=x<=(a**2)*b/2:
		ans=math.atan(((b**2)*a)/(2*x))
	else:
		ans=math.atan((2/a)*(b-(x/a**2)))
	print(math.degrees(ans))






	




if __name__ == '__main__':
	main()

Submission status: Accepted

Solution code:
import sys
sys.setrecursionlimit(10000000)
def input():
    return sys.stdin.readline()[:-1]
# from bisect import *
# from collections import *
# from heapq import *
# import itertools
import math
# INF = 10**9
# MOD = 10**9+7

a, b, x = map(int, input().split())
l, r = 0.0, 90.0
ep = 10**(-7)
for i in range(100):
    m = (l+r)/2
    t = math.radians(m)
    if a*math.sin(t) >= b*math.sin(math.pi/2-t):
        y = b*a*b*math.tan(math.pi/2-t)/2
    else:
        y = a*a*(b+b-a*math.tan(t))/2
    if abs(x-y) < ep:
        break
    if y < x:
        r = m
    else:
        l = m
print(m)

Submission status: Accepted

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

import math

if x <= a**2*b/2:
    a2 = 2*x/(a*b)
    print(math.degrees(math.atan2(b, a2)))
else:
    b2 = 2*(b-x/(a**2))
    print(math.degrees(math.atan2(b2, a)))

Submission status: Accepted

Solution code:
import math

a, b, x = map(int, input().split())
v = a * a * b
if(x <= v / 2):
    h = 2 * x / a / b
    ans = math.degrees(math.atan(b / h))
else:
    h = (v - x) / a / a * 2
    ans = math.degrees(math.atan(h / a))

print(ans)

Submission status: Accepted

Solution code:
import math
a,b,x = map(int,input().split())
if x >= (a**2)*b/2:
    k = (a**2)*b - x
    print(math.degrees(math.atan(2*k/a**3)))
else:
    print(math.degrees(math.atan(a*(b**2)/(2*x))))

Submission status: Accepted

Solution code:
import math
a,b,x =map(int,input().split( ))
if x >= (a**2*b/2):
    k=2*x/(a**2)-b
    cos=math.sqrt((b-k)**2/((a**2)+(b-k)**2))
else:
    k=2*x/(a*b)
    cos=math.sqrt(b**2/(b**2+k**2))
print(90-math.degrees(math.acos(cos)))

Submission status: Accepted

Solution code:
import sys
import math
input = sys.stdin.readline
a, b, x = map(int, input().split())
if x <= a ** 2 * b / 2:
  y = x / (a * b / 2)
  res = math.degrees(math.atan(y / b))
  print(90.0 - res)
else:
  y = 2 * b - 2 * x / (a ** 2)
  res = math.degrees(math.atan(y / a))
  print(res)

Submission status: Accepted

Solution code:
from math import tan, radians
a,b,x=map(int,input().split())
def f(d):
    if a*tan(radians(d))<b:
        return a*(a*b-a**2*tan(radians(d))/2)-x
    else:
        return a*b**2/2/tan(radians(d))-x
ld,rd=0,90-1e-6
while rd-ld>10**(-7):
    md=(rd+ld)/2
    if f(md)>0:
        ld=md
    else:
        rd=md
print(md)

Submission status: Accepted

Solution code:

import math
A, B, X = map(int, input().split())
pi = 3.14159265359

if X == A*A*B:
    print("0")
elif X <= A*A*B/2:
    print(math.atan(A*B*B/2/X)/pi*180)
else:
    print(math.atan(2*(A*A*B-X)/(A*A*A))/pi*180)

Submission status: Accepted

Solution code:
import math
a, b, x = map(int, input().split())
cap = a*a*b
c = 0
if x > cap/2:
    c = ((cap-x) * 2 / (a**2)) / a
else: c = b / (x * 2 / (a * b))
print(math.degrees(math.atan(c)))

Submission status: Accepted

Solution code:
import math
a,b,x = map(int,input().split())
s = (2*a**2*b-2*x)/a**3
t = 2*x/(a*(b**2))
if x >= a**2*b//2:
  ans = math.degrees(math.atan(s))
else:
  ans = 90-math.degrees(math.atan(t))
print(ans)

Submission status: Accepted

Solution code:
import math
a,b,x = map(int,input().split())
if x >= a*a*b/2:
  rest = a*a*b-x
  n = rest*2/a/a
  print(math.degrees(math.atan(n/a)))
else:
  n = x*2/b/a
  print(math.degrees(math.atan(b/n)))

Submission status: Accepted

Solution code:
a,b,x = map(int,input().split())
import math
if a*a*b/2>x:
  #print((-1*(math.atan((2*x)/(a*b*b))-(2/math.pi)))*180/math.pi)
  print((math.atan(a*b*b/(2*x))*180/math.pi))
elif a*a*b/2 == x:
  print((math.atan(b/a))*180/math.pi)
else:
  print((math.atan((2*a*a*b-2*x)/a**3))*180/math.pi)

Submission status: Accepted

Solution code:
from math import atan,pi
a,b,x=map(int,input().split())
if a**2*b>=2*x:
    try:
        print(90-atan(2*x/(a*b**2))*180/pi)
    except: print(0)
else:
    try:
        print(90-atan(a**3/(2*a**2*b-2*x))*180/pi)
    except: print(0)

Submission status: Accepted

Solution code:

import math
a,b,x = map(int,input().split())
if x >= a*a*b/2:
    deru = a*a*b - x
    tans = deru*2/(a*a*a)
    atan1 = math.degrees(math.atan(tans))
else:
    tans = b*b*a/2/x
    atan1 = math.degrees(math.atan(tans))
print(atan1)

Submission status: Accepted

Solution code:
from math import atan, degrees

a,b,x = map(int,input().split())
if a * a * b == x * 2:
    print(45)
elif a * a * b > x * 2:
    t = 2 * x / (a * b * b)
    print(90 - degrees(atan(t)))
else:
    h = (2 / a) * (a * b - x / a)
    print(degrees(atan(h / a)))

Submission status: Accepted

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

#l = bから引いた長さ、三角形の短辺・
#(b-l/2)*a*a = x
if a*a*b/2 < x:
    l =(b-x/(a*a))*2
    # print("M")
    # print(l)
    print(math.degrees(math.atan(l/a)))
#l = aから引いた長さ、三角形の短辺・
#(a-l)*a*b/2 = x
else:
    l =a-(2*x)/(a*b)
    # print("N")
    # print(l)
    print(90-math.degrees(math.atan((a-l)/b)))

Submission status: Accepted

Solution code:
import numpy as np

a,b,x = map(float,input().split())

s = a*a
y1 = 2.0*(s*b-x)/a/a
t1 = y1 / a
y2 = 2.0*x/a/b
t2 = 1.0/(y2 / b)
theta1 = np.rad2deg(np.arctan(t1))
theta2 = np.rad2deg(np.arctan(t2))
if(y1 <= b):print(theta1)
else:print(theta2)

Submission status: Accepted

Solution code:
import math
a, b, x = list(map(int, input().split()))
if x > a**2 * b / 2:
    c = math.atan(2 * (b - x/a**2) / a)
else:
    c = math.atan(a*b**2 / (2 * x))
pi = math.pi
print(c * 180 / pi)

Submission status: Accepted

Solution code:
import math
[a,b,x] = [int(i) for i in input().split()]
if (a * a * b / 2) <= x:
    ans = 2 * x /(a*a) - b
    #print(ans)
    ans = math.degrees(math.atan((b - ans)/a))
    print(ans)
else:
    ans = 2 * x / (b * a)
    ans = math.degrees(math.atan(b/ans))
    print(ans)

Submission status: Accepted

Solution code:
import sys
from heapq import heappop, heappush
from operator import itemgetter
from collections import deque, defaultdict, Counter
from bisect import bisect_left, bisect_right
input = sys.stdin.readline
sys.setrecursionlimit(10 ** 7)
MOD = 10**9 + 7
INF = float('inf')
EPS = 1e-8

from math import tan, degrees, pi, atan2

def sol():
    a, b, x = map(int, input().split())
    deg1 = atan2(b, a)

    def isOk(deg):
        if deg > deg1:
            z = min(a, b / tan(deg))
            value = b * z * a / 2
            if x <= value:
                return True
            else:
                return False
        else:
            deg = pi / 2 - deg
            z = min(b, a / tan(deg))
            value = a * a * b - (z * a * a / 2)
            if x <= value:
                return True
            else:
                return False

    ok = 0.0
    ng = pi / 2

    while abs(ok - ng) > EPS:
        mid = (ok + ng) / 2
        if isOk(mid):
            ok = mid
        else:
            ng = mid

    print(degrees(ok))

sol()

Submission status: Accepted

Solution code:
import sys
import math
input = sys.stdin.readline


def main():
    a, b, x = map(int, input().split())
    if x >= a*a*b/2:
        tanx = (2/a) * (b - (x/(a**2)))
        print(math.degrees(math.atan(tanx)))
    else:
        tanx = (2*x) / (a*b**2)
        print(90 - math.degrees(math.atan(tanx)))


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
import math

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

ansrad = 0

if x/a/a > b/2:
    ansrad = math.atan2(b - x / a / a, a / 2)
else:
    ansrad = math.atan2(b, 2 * x / a / b)

print(ansrad * 180 / math.pi)

Submission status: Accepted

Solution code:
import math
import sys
#input = sys.stdin.readline
sys.setrecursionlimit(10**7)
a, b, x = map(int, input().split())

if a*a*b == x:
	print(0)

elif a*a*b/2 < x:
    l = 2*b - 2*x/(a*a)
    print(90 - math.degrees(math.atan(a/l)))

elif a*a*b/2 == x:
    print(90 - math.degrees(math.atan(a/b)))

else:
    l = 2*x / (a*b)
    print(90 - math.degrees(math.atan(l/b)))

Submission status: Accepted

Solution code:
import sys

sys.setrecursionlimit(10**7)
INF = 10 ** 18
MOD = 10 ** 9 + 7
def LI(): return list(map(int, sys.stdin.readline().split()))
def II(): return int(sys.stdin.readline())
def LS(): return list(map(list, sys.stdin.readline().split()))
def S(): return list(sys.stdin.readline())[:-1]

import math

def main():
    a, b, x = LI()
    r = a*a*b - x

    if r < x:
        h = r *2 / a / a
        print(math.degrees(math.atan(h/a)))
    else:
        h = x *2 / a / b
        print(90 - math.degrees(math.atan(h/b)))


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
# import sys
#
# sys.setrecursionlimit(10 ** 7)
#
# input = sys.stdin.readline
# rstrip()

# int(input())
# map(int, input().split())

from math import atan, degrees

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

# 三角柱
w = x * 2 / (a * b)
if 0 <= w <= a:
    print(degrees(atan(b / w)))
    exit()

# 台形柱
h = x * 2 / (a ** 2) - b
print(degrees(atan((b - h) / a)))

Submission status: Accepted

Solution code:
a,b,x= input().split()
a= float(a)
b= float(b)
x= float(x)

import math

upper = b - (x / a / a)
under = a/2
if upper <= (b/2):
    print(math.degrees(math.atan(upper/under)))
else:
    print(math.degrees(math.atan(b/(2*x/a/b))))

Submission status: Accepted

Solution code:
import math
atan = math.atan
deg = math.degrees
a,b,x = map(float,input().split())
if 2*x >= a*a*b:
    h = x/(a*a)
    print(deg(atan(2*(b-h)/a)))
else:
    h = x/(a*a)
    print(90.0-deg(atan(2*a*h/(b*b))))

Submission status: Accepted

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

if x <= (a**2 * b)/2:
    ans = (180 * math.atan((a*b**2)/(2*x)))/(math.pi)
    print(ans)
    
else:
    ans = (180 * math.atan((2*a**2*b - 2*x)/(a**3)))/(math.pi)
    print(ans)

Submission status: Accepted

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

if 2*x<=(a**2)*b:
        a=math.degrees(math.atan((b**2)*a/(2*x)))
        print(a)
else:
        a=math.degrees(math.atan((2*(a**2*b-x))/a**3))   
        print(a)

Submission status: Accepted

Solution code:
from math import atan, pi
a, b, x = map(int, input().split())

if x > (a ** 2 * b / 2):
    print(atan(2 * (a ** 2 * b - x) / a ** 3) * 180 / pi)
else:
    print(atan((a * b ** 2) / (2 * x)) * 180 / pi)

Submission status: Accepted

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

if 2*x/a/b <= a:
    z = 2*x/a/b
    d = math.degrees(math.atan(b/z))
else:
    y = 2*x/(a**2) -b
    d = math.degrees(math.atan((b-y)/a))
print(d)

Submission status: Accepted

Solution code:
import numpy as np
a,b,x=map(int,input().split())
l=x/(a*a)
if l*2>=b:
  print(np.degrees(np.arctan2(b-l,a/2)))
else:
  r=a*l*2/b
  print(np.degrees(np.arctan2(b,r)))

Submission status: Accepted

Solution code:
import math
a,b,x=map(int,input().split())
t=0
if x>=a*a*b/2:
  c=2*x/a/a-b
  t=math.degrees(math.atan((b-c)/a))
else:
  c=2*x/a/b
  t=math.degrees(math.atan(b/c))


print(t)

Submission status: Accepted

Solution code:
import math

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

if (a*b)/2 == x/a:
    print(45)
elif (a*b)/2 < x/a:  # 水が溢れる瞬間、水面が底面に達しない
    tmp = 2*(b - x/a**2)
    print(math.degrees(math.atan(tmp/a)))
else:
    tmp = (2*x)/(a*b)
    print(math.degrees(math.atan(b/tmp)))

Submission status: Accepted

Solution code:
import math

a, b, x = [int(i) for i in input().split()]

if x*2 > a*a*b:
    rest = a*a*b - x
    #h = 2*rest / a*a
    #print(math.degrees(math.atan2(a, h)))
    print(90 - math.degrees(math.atan2(a*a*a, 2*rest)))
else:
    print(90 - math.degrees(math.atan2(2*x, a*b*b)))

Submission status: Accepted

Solution code:
import math
a, b, x = map(int, input().split())
c = x / a
if c <= a * b / 2:
    h = 2 * c / b
    t = 180 * math.atan(h / b) / math.pi
    print(90 - t)
else:
    c = a * b - c
    h = 2 * c / a
    t = 180 * math.atan(h / a) / math.pi
    print(t)

Submission status: Accepted

Solution code:
import math

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


if a*a*b >= x*2:
  d = 2*x/a/b
  print(math.atan(b/d)*180/math.pi)
else:
  d = 2*x/a/a - b
  print(math.atan((b-d)/a)*180/math.pi)

Submission status: Accepted

Solution code:
import math

a, b, x = list(map(float, input().split()))
s = x / a
if(s * 2 > a * b):
    print(math.degrees(math.atan(2*(a*b-s)/(a*a)))) 
elif(s * 2 == a * b):
    print(45.0)
else:
    print(math.degrees(math.atan(b*b/(2*s))))

Submission status: Accepted

Solution code:
a,b,x = [int(x) for x in input().split()]
sq = x/a
sq2 = a*b - sq
if sq2 <= a*b/2:
  line = sq2*2/a+0.00000001
  import math 
  #print(sq,sq2,line)
  t = 90-math.degrees(math.atan(a/line))
  print(t)
else:
  line = sq*2/b+0.00000001
  import math 
  #print("a",sq,sq2,line)
  t = 90-math.degrees(math.atan(line/b))
  print(t)

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
from operator import itemgetter
sys.setrecursionlimit(10000000)
from math import atan, pi

def main():
    a, b, x = map(int, input().strip().split())
    if x > a **2 * b / 2:
        print(atan(2 * (a**2*b - x)/ a ** 3) * 180/pi)
    else:
        print(90 - atan(2 * x / (a * b ** 2)) * (180 / pi))

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
#A=int(input())
#A=list(map(int,(input().split())))
import math
a,b,x=list(map(int,(input().split())))
mmax=a*a*b
if(mmax/2<=x):#半分以上
	kakudo=math.atan((mmax-x)*2/(a**3))
	print(math.degrees(kakudo))
else:
	kakudo=math.atan(x*2/(a)/(b**2))
	print(90-math.degrees(kakudo))

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
#ABC144D
import sys
import math
import collections
#sys.setrecursionlimit(100000)


#n=int(input())

tmp = input().split()
a,b,x = list(map(lambda a: int(a), tmp))

#print(2*x/a/b)
#print(math.degrees(math.atan(1/1.732)))

if(a**2*b>2*x):
	print(90-math.degrees(math.atan(2*x/a/b/b)))
else:
	print(math.degrees(math.atan((a**2*b-x)*2/(a**3))))

Submission status: Accepted

Solution code:
import math

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

if x/a >= a*b/2:
    tmp = (b - ( 2 * x /(a*a) -b))/a
    ans  = math.degrees(math.atan(tmp))
else :
    ans = 90 - math.degrees(math.atan(2*x / a / b/ b))
print(ans)

Submission status: Accepted

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

h = x / (a*a)

if h > b / 2:
    ans = math.degrees(math.atan((b-h) / (a/2)))
else:
    ans = math.degrees(math.atan(a*b*b/(2*x)))

print(ans)

Submission status: Accepted

Solution code:
import math
a,b,x=map(int,input().split())
S=a*b-x/a
if S<=a*b/2:
    aaa=S*2/(a*a)
    ans=math.degrees(math.atan(aaa))
    print(ans)
else :
    S=x/a
    aaa=S*2/(b*b)
    ans=math.degrees(math.atan(aaa))
    print(90-ans)

Submission status: Accepted

Solution code:
import math
a, b, x=(int(i) for i in input().split())

if a**2*b==x:
    print(0)
elif a**2*b//2<=x:
    ans_tan=2*(a*a*b-x)/a**3
    ans=math.degrees(math.atan(ans_tan))
    print(ans)
else:
    ans_tan=2*x/(a*b**2)
    ans=math.degrees(math.atan(ans_tan))
    print(90-ans)

Submission status: Accepted

Solution code:
import math

a,b,x=map(int,input().split())
vol=a*a*b/2
t=0

if x == vol:
    t = b/a

elif x < vol:
    t = a*b*b/2/x

else:
    t = 2*b/a - 2*x/a/a/a

ans=math.degrees(math.atan(t))
print(ans)

Submission status: Accepted

Solution code:
import math

tmp = list(map(int,input().split()))
a = tmp[0]
b = tmp[1]
x = tmp[2]

h = x / (a * a)


if h > b / 2:
  t = 2 * h - b
  r = math.degrees(math.atan((b - t) / a))
else:
  y = 2 * x / (a * b)
  r = math.degrees(math.atan(b / y))
  
print (r)

Submission status: Accepted

Solution code:
import math
a, b, x = map(int, input().split())
if x <= a*a*b//2:
    ans = 90 - math.degrees(math.atan(2*x/(a*b*b)))
else:
    ans = math.degrees(math.atan(2*(a*a*b-x)/(a*a*a)))
print(ans)

Submission status: Accepted

Solution code:
# coding: utf-8
import math
a, b, x = map(int, input().split())
h = x / a ** 2
l = 2 * a * h / b
if l <= a:
    print(math.degrees(math.atan2(b, l)))
elif x == a ** 2 * b:
    print(0)
else:
    k = 2 * h - b
    m = a * b / (k - b)
    print(90 + math.degrees(math.atan2(m, b)))

Submission status: Accepted

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

import numpy as np
from numpy import linalg as LA

if a*a*b<=2*x:
  sanMenseki=(a*a*b-x)/a
  takasa=sanMenseki*2/a
  u = np.array([a,0])
  v = np.array([a,takasa])
  i = np.inner(u, v)
  n = LA.norm(u) * LA.norm(v)

  c = i / n
  a = np.rad2deg(np.arccos(np.clip(c, -1.0, 1.0)))

  print(a)
else:
  sanMenseki=x/a
  takasa=sanMenseki*2/b
  u = np.array([b,0])
  v = np.array([b,takasa])
  i = np.inner(u, v)
  n = LA.norm(u) * LA.norm(v)

  c = i / n
  a = np.rad2deg(np.arccos(np.clip(c, -1.0, 1.0)))

  print(90-a)

Submission status: Accepted

Solution code:
import numpy as np

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

v = a * a * b

if x <= v / 2:
    theta = np.arctan(a * b**2 / (2 * x))
    print(np.rad2deg(theta))

else:
    theta = np.arctan(2 * (v - x) / (a**3))
    print(np.rad2deg(theta))

Submission status: Accepted

Solution code:
import math

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

h = x / a / a
r = b - h
t = 2 * r / a if h >= b / 2 else a * b * b / 2 / x
print(math.degrees(math.atan(t)))

Submission status: Accepted

Solution code:
import math
a, b, x = map(int, input().split())
if a*a*b/2 >= x:
  k = (2*x)/(a*b)
  ans = math.degrees(math.atan(b/k))
else:
  l = a*a*b
  xx = l - x
  k = (2*xx)/(a*a)
  ans = math.degrees(math.atan(k/a))
print(ans)

Submission status: Accepted

Solution code:
import math
a,b,x = map(int, input().strip().split(' '))
if x*2 <= a*a*b:
  ans = 90 - math.degrees(math.atan(x*2/(a*b*b)))
else:
  ans = math.degrees(math.atan((a*a*b-x)*2/(a*a*a)))
print(ans)

Submission status: Accepted

Solution code:
import math
a,b,x = list(map(int,input().split()))
h = x/(a**2)
if b == h:
    ans = 0
elif h<=b/2:
    ans = math.degrees(math.atan(b**2/(2*a*h)))
else:
    ans = 90-math.degrees(math.atan(a/(2*(b-h))))
print(ans)

Submission status: Accepted

Solution code:
import math

a, b, x = map(int, input().split())
result = math.atan(2 * ( a*a*b - x) / (a*a*a))
if a * math.tan(result) > b:
    result = math.pi / 2 - math.atan(2 * x / (a*b*b))

print(math.degrees(result))

Submission status: Accepted

Solution code:
def resolve():
    a, b, x = map(int, input().split())
    if a ** 2 * b / 2 < x:
        t = 2 * (a ** 2 * b - x) / (a ** 3)
    else:
        t = a * b ** 2 / x / 2
    import math
    d = math.degrees(math.atan(t))
    print(d)


if __name__ == '__main__':
    resolve()

Submission status: Accepted

Solution code:
import numpy as np
a,b,x=map(float,input().split())
k=2*(a*a*b-x)*1.0/(1.0*a*a*a)
l=2*x/(1.0*a*b*b)
if a*a*b/2.0<x:
    print(np.rad2deg(np.arctan(k)))
else:
    print(90.0-np.rad2deg(np.arctan(l)))

Submission status: Accepted

Solution code:
from math import atan, degrees

a, b, x = map(int, input().split())
V = a * a * b // 2

if V >= x:
    #print('V >= x')
    l = (2 * x) / (a * b)
    theta = 90 - degrees(atan(l / b))
else:
    h = ((2 * x) / (a * a)) - b
    if b != h:
        theta = 90 - degrees(atan(a / (b - h)))
    else:
        theta = 0

print(theta)

Submission status: Accepted

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

v = a * a * b
if v / 2 < x:
    print(90-math.asin(a/((2*(v-x)/a/a)**2+a**2)**0.5)/math.pi*180)
else:
    print(math.asin(b/((2*x/a/b)**2+b**2)**0.5)/math.pi*180)

Submission status: Accepted

Solution code:
from math import atan, degrees


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

    full = a * a * b
    half = full * 0.5

    if x <= half:
        s = x / a
        ans = 90 - degrees(atan(2 * s / b ** 2))

    else:
        s = (full - x) / a
        if s != 0:
            ans = 90 - degrees(atan(a ** 2 / (2 * s)))
        else:
            ans = 0

    print(ans)


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
import math

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

get_line = a*a*b/2

if x < get_line:
    theta = math.atan((a*b*b)/(2*x))
else:
    theta = math.atan((-2*x+2*a*a*b)/(a*a*a))

theta = math.degrees(theta)

print(theta)

Submission status: Accepted

Solution code:
import math

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

if x>=a*a*b*0.5:
    div=(b-(x/(a**2)))/(a*0.5)
    degr = math.degrees(math.atan(div))
    print(degr)
else:
    teihen=(2*x)/(b*a)
    div=b/teihen
    degr = math.degrees(math.atan(div))
    print(degr)

Submission status: Accepted

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


vmax=b*a*a/2
pi=math.pi
if x<vmax:
    h=2*x/(b*a)
    print(90.0-math.atan(h/b)*180/pi)
else:
    xt=a*a*b-x
    bt=xt/(a*a)
    ht=2*bt
    print(math.atan(ht/a)*180/pi)

Submission status: Accepted

Solution code:
import math
a,b,x=map(int,input().split())
ans = 0
if a*a*b==x:
    ans = math.pi/2
elif a*a*b/2 >= x:
    x/=a
    x=x*2/b
    ans = math.atan(x/b)
else:
    x/=a*a
    x=(b-x)*2
    ans = math.atan(a/x)
print(90-ans/math.pi*180)

Submission status: Accepted

Solution code:
import numpy as np
pi=np.pi
a, b, x=map(int, input().split())

if x>=a*a*b/2:
  c=2*x/(a*a)-b
  theta=180*np.arctan((b-c)/a)/pi
else:
  c=2*x/(a*b)
  theta=180*np.arctan(b/c)/pi
  
print(theta)

Submission status: Accepted

Solution code:
import math


def resolve():
    a, b, x = map(float, input().split())
    h = x / (a ** 2)
    if h >= b / 2:
        degree = math.degrees(math.atan(2 * (b - h) / a))
    else:
        degree = math.degrees(math.atan(b ** 2 / (2 * a * h)))
    print(degree)


if __name__ == "__main__":
    resolve()

Submission status: Accepted

Solution code:
import math
a, b, x = map(int, input().split())
if x <= a*a*b/2:
    # y = b/tan(z)
    y = 2 * x / (a * b)
    tanz = b / y
    z = math.degrees(math.atan(tanz))
    print(z)
else:
    # y = atan(z)
    x = a * a * b - x
    y = 2 * x / (a * a)
    tanz = y / a
    z = math.degrees(math.atan(tanz))
    print(z)

Submission status: Accepted

Solution code:
import math

a, b, x = map(int,input().split())
h = x / (a*a)
if h >= (b/2):
    k = 2*h - b
    print(str(math.degrees(math.atan((b-k)/a))))
else:
    a_prime = (2*x)/(a*b)
    print(str(math.degrees(math.atan(b/a_prime))))

Submission status: Accepted

Solution code:
import math
a, b, x = [ int(v) for v in input().split() ]
v = a*a*b

if x < v/2:
    print(math.atan(b*b*a/(2*x))*(180/math.pi))
else:
    print(math.atan(2*(v-x)/(a**3))*(180/math.pi))

Submission status: Accepted

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

if a ** 2 * b / 2 <= x:
    theta = math.atan(2 * b / a - 2 * x / (a ** 3))
    print(180 * theta / math.pi)
else:
    theta = math.pi / 2 - math.atan(2 * x / (a * b ** 2))
    print(180 * theta / math.pi)

Submission status: Accepted

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


if x >= a**2 * b / 2:
    t = 2*x/a**2 - b
    print(180 * math.atan2(b-t,a) / math.pi)
else:
    t = 2*x / (a*b)
    print(180 * math.atan2(b,t) / math.pi)

Submission status: Accepted

Solution code:
import sys
import math
def input():
    return sys.stdin.readline()[:-1]
a,b,x=map(int,input().split())
if a*a*b/2>x:
    y=float(2*x)/a/b
    tai=pow(y*y+b*b,0.5)
    print(90-math.degrees(math.asin(y/tai)))
else:
    x=a*a*b-x
    y=float(2*x)/a/a
    tai=pow(y*y+a*a,0.5)
    print(math.degrees(math.asin(y/tai)))

Submission status: Accepted

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

if x < a*a*b/2:
    h = b
    v = 2*x/(a*b)
else:
    h = 2*(a*a*b-x)/(a*a)
    v = a
angle = math.degrees(math.atan(h/v))
print(angle)

Submission status: Accepted

Solution code:
import math
a, b, x = [float(x) for x in input().split()]
x = x / a
if 2 * x < a * b:
  print(90 - 180.0* math.atan2(2*x/b, b)/math.pi)
else:
  print(180.0* math.atan2(2*(a*b-x)/a, a)/math.pi)

Submission status: Accepted

Solution code:
import math

def main():
    # input
    a, b, x = map(int, input().split())

    # calc
    if x <= a*a*b/2:
        ans = math.degrees(math.atan(2*x/a/b/b))
        print(90-ans)

    else:
        y = a*a*b - x
        ans = math.degrees(math.atan(2*y/a**3))
        print(ans)


if __name__ == '__main__':
    main()