Submission #2474

# Submission time Handle Problem Language Result Execution time Memory
2474 2013-07-22T10:45:45 Z gs12037 개미 (GA4_ant) C++
48 / 100
60 ms 884 KB
#include <stdio.h>
#include <vector>
using namespace std;
int main(){
	int test,a,b,c,ans;
	scanf("%d",&test);
	for (int t=1;t<=test;t++){
		scanf("%d %d %d",&a,&b,&c);
		ans=(a+b)*(a+b)+c*c;
		ans=min(ans,(b+c)*(b+c)+a*a);
		ans=min(ans,(c+a)*(c+a)+b*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 48 ms 884 KB Output isn't correct
# Verdict Execution time Memory Grader output
1 Correct 51 ms 884 KB Output is correct
# Verdict Execution time Memory Grader output
1 Incorrect 50 ms 884 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 49 ms 884 KB Output is correct
# Verdict Execution time Memory Grader output
1 Incorrect 60 ms 884 KB Output isn't correct
2 Halted 0 ms 0 KB -