C: problem with char*

前端 未结 7 398
遥遥无期
遥遥无期 2021-01-22 07:38
/*
 * code.c
 *
 * TASK
 *      Reverse a string by reversing pointers. Function should use return
 *      type char* and use a char* parameter as input.
 */
#include &l         


        
相关标签:
7条回答
  • 2021-01-22 08:11

    Type char* sPhrase[] is really incompatible with char *, [] has semantic of pointer, so you code much to char **. So function signature must be:

    char* reverse(char* sPhrase)
    
    0 讨论(0)
提交回复
热议问题