func_code_string: #include <bits/stdc++.h>   using namespace std;   int key;   long long dis[1000];   struct pt {     long long x, y, z;   } f[8], point[8];   long long meow(int a, int b) {     long long ta, tb, tc;     ta = f[a].x - f[b].x;     tb = f[a].y - f[b].y;     tc = f[a].z - f[b].z;     return (ta * ta + tb * tb + tc * tc);   }   int chk() {     int i, j, cnta, cntb, cntc, k;     long long dis, sq2, sq3, ik;     for (i = 0; i < 8; i++) {       for (j = 0; j < 8; j++) {         if (i != j && f[i].x == f[j].x && f[i].y == f[j].y && f[i].z == f[j].z)           return false;       }     }     for (i = 0; i < 8; i++) {       for (j = 0; j < 8; j++) {         dis = meow(i, j);         cnta = cntb = cntc = 0;         for (k = 0; k < 8; k++) {           ik = meow(i, k);           if (ik == dis) cnta++;           if (ik == dis * 2) cntb++;           if (ik == dis * 3) cntc++;         }         if (cnta == 3 && cntb == 3 && cntc == 1) break;       }       if (j == 8) return false;     }     return true;   }   void go(int r) {     if (r == 8) {       if (chk()) {         key = 1;         cout <<  YES  << endl;         for (int i = 0; i < 8; i++)           cout << f[i].x <<     << f[i].y <<     << f[i].z << endl;       }       return;     }     f[r] = point[r];     go(r + 1);     if (key) return;     swap(f[r].x, f[r].y);     go(r + 1);     if (key) return;     swap(f[r].y, f[r].z);     go(r + 1);     if (key) return;     swap(f[r].x, f[r].y);     go(r + 1);     if (key) return;     swap(f[r].y, f[r].z);     go(r + 1);     if (key) return;     swap(f[r].x, f[r].y);     go(r + 1);     return;   }   int main() {     int i;     for (i = 0; i < 8; i++) cin >> point[i].x >> point[i].y >> point[i].z;     key = 0;     f[0] = point[0];     go(1);     if (!key) cout <<  NO  << endl;     return 0;   }   