Submission #8159935


Source Code Expand

Copy
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner scn = new Scanner(System.in);
		double a = scn.nextInt(), b = scn.nextInt(), x = scn.nextInt();
		if(x <= a*a*b/2) {
			double h = x/(a*b)*2;
			System.out.println(90.0-Math.atan2(h, b)/Math.PI*180);
		}else {
			double h =(a*b*a-x)/(a*a)*2;
			System.out.println(Math.atan2(h,a)/Math.PI*180);
		}
	}

}

Submission Info

Submission Time
Task D - Water Bottle
User hururu
Language Java8 (OpenJDK 1.8.0)
Score 400
Code Size 421 Byte
Status AC
Exec Time 97 ms
Memory 22612 KB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 400 / 400
Status
AC × 3
AC × 15
Set Name Test Cases
Sample sample00, sample01, sample02
All handmade03, handmade04, random05, random06, random07, random08, random09, random10, random11, random12, random13, random14, sample00, sample01, sample02
Case Name Status Exec Time Memory
handmade03 AC 96 ms 21716 KB
handmade04 AC 96 ms 18900 KB
random05 AC 94 ms 21204 KB
random06 AC 96 ms 21204 KB
random07 AC 93 ms 21844 KB
random08 AC 95 ms 19792 KB
random09 AC 95 ms 20692 KB
random10 AC 96 ms 21460 KB
random11 AC 96 ms 22612 KB
random12 AC 95 ms 21716 KB
random13 AC 93 ms 19156 KB
random14 AC 94 ms 21204 KB
sample00 AC 94 ms 18768 KB
sample01 AC 94 ms 19924 KB
sample02 AC 97 ms 19028 KB