// testing of Characters category.
#import <stdio.h>
#import <stdlib.h>
#import <signal.h>
#import <fcntl.h>
#import <string.h>
#import <sys/time.h>
#import <RCString.h>

int
main(int c, char **v)
{
	RCString *oString;

	oString = [RCString newFromString:v[1]];
	if (oString) {
		int first = [oString indexOfCharacter:*v[2]];
		int last =  [oString lastIndexOfCharacter:*v[2]];

		printf("first index of %c in \"%s\" is %d\n", *v[2],
			[oString data], first);
		printf("last index of %c in \"%s\" is %d\n", *v[2],
			[oString data], last);

		[oString free];
	} else {
		fprintf(stderr, "newFromString: failure\n");
		return(1);
	}
	return(0);
}
