Submission #19730

#TimeUsernameProblemLanguageResultExecution timeMemory
19730LK149창문 (kriii4_C)C++98
0 / 100
0 ms1084 KiB
#include <stdio.h> int main () { int h, w; float sum = 0, s; scanf ("%d %d", &h, &w); for (int i = 1; i <= h; i++) { for (int j = 1; j <= w; j++) { for (int k = 1; k <= h - i + 1; k++) { for (int l = 1; l <= w - j + 1; l++) { sum += i * j; } } } } s = (float)h * (h + 1) / 2; s = (float)s * w * (w + 1) / 2; sum = sum / s * 9; printf ("%d", (int)sum); }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...