/********************************************************************* * * Purpose: Reverse characters in a string. * Author: K&R * Date: * *********************************************************************/ void reverse(char s[]); main() { char text[80]="martin"; printf("string is %s\n", text); reverse(text); printf("string is %s\n", text); } void reverse(char s[]) { int c, i, j; for (i=0, j=strlen(s)-1; i < j;i++, j--) { c = s[i]; s[i] = s [j]; s[j] = c; } } ink rel='vcs-git' href='http:///git.distanz.ch/cgit.cgi/linux/net-next.git' title='net-next.git Git repository'/>
summaryrefslogtreecommitdiff
path: root/drivers/usb/host/fhci-tds.c
AgeCommit message (Expand)AuthorFilesLines