How to use char in C -


i'm struggling char work. keeps returning error.

#include <stdio.h> #include <cs50.h> int main (void)  { int tower_height; char #;  //                          inputs         {          printf("let's build! give me number between 0 , 23 'inclusive'.\n");     tower_height = getint(); }    while      (tower_height < 0 || tower_height > 23);   //                          outputs  (tower_height = 0; tower_height <= 23; tower_height++) printf ("%c = tower_height - 2\n");  }    

as pointed out, # not valid variable name. can see how # used in first line of code: #include <stdio.h>

instead, call char variable uses letters , numbers eg: char c;


Comments

Popular posts from this blog

google api - Incomplete response from Gmail API threads.list -

Installing Android SQLite Asset Helper -

Qt Creator - Searching files with Locator including folder -