#include<iostream>#include<cstdio>#include<algorithm>usingnamespace std;intmain(){int t;scanf("%d",&t);int x, y, z, a=0, b=0, c=0, flag=1;while(t--){
flag =0;scanf("%d%d%d",&x,&y,&z);if(x == y && y == z){
flag =1; a=x,b=y,c=z;}elseif(x == y && y > z){
flag =1; a = x, b = z, c = z;}elseif(x == z && z > y){
flag =1; a = y, b = x, c = y;}elseif(y == z && z > x){
flag =1; a = x, b = x, c = y;}if(flag){puts("YES");printf("%d %d %d\n", a, b, c);}else{puts("NO");}}return0;}