#include <stdio.h> int main() { int n; while (scanf("%d", &n) != EOF) { for (int i = 0; i < 101; i++) { for (int j = 0; j < 101; j++) { for (int k = 0; k < 101; k++) { //避免浮点数精度问题,两端同时乘以三 if ((i * 15 + j * 9 + k <= 3*n) && (i + j + k ==100)) { printf("x=%d,y=%d,z=%d\n", i, j, k); } } } } } return 0; }