Submission #2170

# Submission time Handle Problem Language Result Execution time Memory
2170 2013-07-20T06:53:24 Z cki86201 개미 (GA4_ant) C++
48 / 100
56 ms 884 KB
#include<stdio.h>
#include<algorithm>

int a,b,c;

int main()
{
	int t;scanf("%d",&t);
	while(t--){
		scanf("%d%d%d",&a,&b,&c);
		int ans=2e9;
		ans=std::min(ans,a*a+(b+c)*(b+c));
		ans=std::min(ans,b*b+(a+c)*(a+c));
		ans=std::min(ans,c*c+(a+b)*(a+b));
		printf("%d\n",ans);
	}
	return 0;
}
# Verdict Execution time Memory Grader output
1 Correct 45 ms 884 KB Output is correct
# Verdict Execution time Memory Grader output
1 Incorrect 47 ms 884 KB Output isn't correct
# Verdict Execution time Memory Grader output
1 Correct 46 ms 884 KB Output is correct
# Verdict Execution time Memory Grader output
1 Incorrect 52 ms 884 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 53 ms 884 KB Output is correct
# Verdict Execution time Memory Grader output
1 Incorrect 56 ms 884 KB Output isn't correct
2 Halted 0 ms 0 KB -