#include #include #include #include #include #include #include char* canConstruct(int a_size, int* a) { // Return "Yes" or "No" denoting whether you can construct the required number. int count=0; for (int a_i = 0; a_i < a_size; a_i++) { count=count+a[a_i]; } if(count%3==0) { printf("Yes\n"); return ; } else printf("No\n"); return ; } int main() { int t; scanf("%i", &t); for(int a0 = 0; a0 < t; a0++){ int n; scanf("%i", &n); int *a = malloc(sizeof(int) * n); for (int a_i = 0; a_i < n; a_i++) { scanf("%i",&a[a_i]); } int result_size; char* result = canConstruct(n, a); //printf("%s\n", result); } return 0; }