Search results

  1. J

    [TuT] Recursive function to reverse an array of characters

    Hi, This code causes the reversal of an array of characters using a recursive function. #include <stdio.h> void inv(char *string) { if(*string) { inv(string+1); putchar(*string); } } int main() { inv("kleber"); return 0; } Explaining: int main () ( inv ( "linux"); / / when you call the...
Back
Top