c - It is not able to display message -
// To display the message as a parameter, use the function # include & lt; Stdio.h & gt; #to & lt include, process.h & gt; // Return name char name_desplay (four * name) {return * name; } // display name zero performance (four (* display) (four * name1), four * name 2) {char name3; NAME3 = Performance (NAME2); Printf ("name is% s", name3); } Zero main () {display (name_display, "message");
Definitely: printf ("name is% s" Name3);
wants to print a string, but name3
is only a char
or modify your code:
printf ("Name% c", name3);
or modify your code:
four * name_display (four * names) {return name; } // Display Name is zero display (four * (* display) (four * name1), four * name 2) {four * name3; I.e.: Work with strings instead of letters.
Comments
Post a Comment