#include <stdio.h> int main(){ int n; int count=0; double sum; if (scanf("%d",&n)!=EOF){ for (int cnt_m=0;cnt_m<n;cnt_m++){ for (int cnt_w=0;cnt_w<n;cnt_w++){ for (int cnt_c=0;cnt_c<n;cnt_c++){ sum = 3*cnt_m+2*cnt_w+0.5*cnt_c; if (sum==n*1.0 && (cnt_m+cnt_w+cnt_c==n)){ printf("men = %d, women = %d, child = %d\n",cnt_m,cnt_w,cnt_c); count++; } } } } if (count==0){printf("None");} } else{ printf("input wrong"); } return 0; }