Rechercher une page de manuel
strrev.3pub
Langue: en
Version: C Programmer's Manual (debian - 07/07/09)
Section: 3 (Bibliothèques de fonctions)
NAME
strrev - reverse a string in placeSYNOPSIS
#include <publib.h> char *strrev(char *str);
DESCRIPTION
strrev reverses the argument string in place, i.e., it swaps the ith character from the beginning with the ith character from the end.RETURN VALUE
strrev returns its argument.EXAMPLE
Reversing "dlrow, elloh" would be done like the following.char str[] = "dlrow, elloh"; puts(strrev(str));This would output "hello, world". Note that using the string literal as the argument would be an error, since it is not allowable to modify string literals.
BUGS
Does not automatically detect palindromes, nor automatically return without doing anything.SEE ALSO
publib(3), memrev(3)AUTHOR
Lars Wirzenius (lars.wirzenius@helsinki.fi)Contenus ©2006-2024 Benjamin Poulain
Design ©2006-2024 Maxime Vantorre