#include<stdio.h>
#include<string.h>
#include<stdlib.h>

int main() {

	char s[9][5]={".,!? ","abc","def","ghi","jkl","mno","pqrs","tuv","wxyz"};
	char answer[76],enter[1025];
	int n,i,j,k,l,r,flag;

	scanf("%d",&n);
	for(i=0;i<n;i++) {
		scanf("%s",enter);
		for(j=0;j<76;j++)
			answer[j]='\0';

		flag=0;
		k=0;
		l=0;
		r=-1;
		for(j=0;j<=strlen(enter)-1;j++) {
			if(flag&&enter[j]=='0') {
				if(l==6||l==8)
					answer[k]=s[l][r%4];
				else if(l==0)
					answer[k]=s[l][r%5];
				else
					answer[k]=s[l][r%3];
				k++;
				flag=0;
				r=-1;
			}
			else if(enter[j]-'0'>0) {
				flag=1;
				l=(enter[j]-'0')-1;
				r++;
			}
		}
		printf("%s\n",answer);
	}

	return 0;
}