pdp11v/usr/src/games/master/equal.c

Compare this file to the similar file:
Show the results in this format:

static char ID[] = "@(#)equal.c	1.1";

/*
 *	Compares strings a and b for equality; returns 1 if
 *	equal, 0 of not. Both strings are assumed to be terminated
 *	by a null character.
 */
equal(a, b)
	char *a, *b;
{
	while (*a == *b && *a != '\0') {
		a++;
		b++;
	}
	return *a == *b;
}