Follows 10222.c (Total 26 lines):

/* @JUDGE_ID:4461XX 10222 C */
/* A */
#include<stdio.h>
#include<ctype.h>

int main( void )
{
	char encode[45]="234567890-=\\ertyuiop[]dfghjkl;'cvbnm,./" ;
	char decode[45]="`1234567890-qwertyuiopasdfghjklzxcvbnm," ;
	char ch ;
	int i ;

	while( scanf( "%c" , &ch )==1 ){
		ch = tolower( ch ) ;

		for( i=0 ; encode[i] ; ++i )
			if( ch==encode[i] ){
				putchar( decode[i] ) ;
				break ;
			}

		if( !encode[i] ) putchar( ch ) ;
	}
	
	return 0 ;
}

Back to statistics
Ya-Lin Huang (C)
huangyl@gmail.com