All pastes #69270 Raw Edit

bleh

public cpp v1 · immutable
#69270 ·published 2006-06-22 19:13 UTC
rendered paste body
char dabuf[20];bool stop=false;void increment(int cur,char *pointer){	if(cur==20)	{		stop=true;		return;	}	if(pointer[0]==0)	{		pointer[0]='a';		return;	}	if(pointer[0]=='z')	{		pointer[0]='A';		return;	}	if(pointer[0]=='Z')	{		pointer[0]='0';	}	if(pointer[0]=='9')	{		pointer[0]='a';		increment(cur+1,pointer+1);		return;	}	pointer[0]++;}void check(char *dastring){	long index;	long result=0;	for(index=0;index<strlen(dastring);index++)	{		result+=dastring[index];	}	result+=0x96;	if(result==0x21A)	{		printf("Valid: %s\n", dastring);	}}int main(int argc, char *argv[]){	memset(dabuf,0,20);		while(stop==false)	{		check(dabuf);		increment(0,dabuf);	}    return EXIT_SUCCESS;}