# include<stdio.h> int main(){ int n , i , d; char a[ 32 ]; scanf( " %d " , & n); while (n -- ) { scanf( " %s " , a); for (i = 0 ; i < 32 ; i ++ ) { a[i] = a[i] - ' 0 ' ; } d = a[ 0 ]; for (i = 1 ; i < 32 ; i ++ ) { if (i == 8 || i == 16 || i == 24 ) { printf ( " %d. " , d); d = a[i]; } else d = 2 * d + a[i]; } printf ( " %d/n " , d); } return 0 ;}