Follows 272.c (Total 18 lines):

/* @JUDGE_ID:4461XX 272 C */
/* A */
#include <stdio.h>
#include <string.h>
void main( void )
{
	char a[100] ; int check=0 , i ;
	while ( gets( a ) !=NULL )
	{
		for( i=0 ; i<strlen(a) ; i++ )
		{
			if( a[i]=='"' && check%2==0 ) { printf( "``" ) ; check++ ; }
			else if( a[i]=='"' && check%2==1 ) { printf( "''") ; check++ ; }
			else printf( "%c" , a[i] ) ;
		}
		printf( "\n" ) ;
	}
}

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