Re: [CODE]

From: James (prs4@monmouth.com)
Date: 07/18/00


Well, since you want it so optimised ... :P

void upper ( char *string ) {
  int i=strlen(string)-1;
  for (; i<0; CAP(string+(--i)));
}

 .. or ..

void upper(char *buf)
{
  for (; *buf; *buf = UPPER(*(++buf)));
}

Just to be compact ;)


     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     |  http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html  |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 04/10/01 PDT