The following is brought to you thanks, in part, to the kind assistance of CyberNews and the fine folks at Cornell University.
("Quid coniuratio est?")
666 SEARCHER -- C LANGUAGE VERSION
/*
| srchr.c
|
| This is a C implementation of Brian Redman's QuickBasic 666 Searcher.
| You can do whatever you want with it. If one of the things you want
| to do is compile it, then "cc -s -O srchr.c -o srchr" should work on
| both unix and dos. Enjoy!
/
#include <stdio.h>
main(ac, av)
int ac;
char *av;
{
int c, x; char *p, *fgets(), buf[BUFSIZ];
c = ~EOF;
do {
printf("Enter name: ");
if (fgets(buf, sizeof(buf), stdin) == (char *)NULL) break;
for (c = 0, p = buf; p; p++) { if (p == '\n') { *p = '\0'; break; } if ((x = *p) > 90) x -= 32; x -= 64; x *= 6; c += x; } printf("%s = %d\n", buf, c); do{ printf("Again? "); if ((c = getchar()) != EOF) switch (c) { case '\n': continue; case 'y': case 'Y': break; default: c = EOF; } while ((x = getchar()) != EOF && x != '\n'); } while (c != 'y' && c != 'Y' && c != EOF);
} while (c != EOF);
printf("Thank you for using 666 Searcher.\n");
exit(0);
}
I encourage distribution of "Conspiracy Nation."
For information on how to receive the improved Conspiracy Nation Newsletter, send an e-mail message to bigred@shout.net
See also: http://www.europa.com/~johnlf/cn.html
See also: ftp ftp.shout.net pub/users/bigred