Thread: string help
View Single Post
Old Feb 24th, 2005, 9:08 PM   #8
AlphaXero
Newbie
 
Join Date: Feb 2005
Posts: 8
Rep Power: 0 AlphaXero is on a distinguished road
how did he chabne the if statement? and here is my full code
-

#include <stdio.h>

start()
{
    char str[80];
    printf ("you see a door what do you do?\n");
    scanf ("%s", str);
    if (str "door" == 0)
     {
       printf ("you get to the door");
     }
}

main()
{
   printf ( "welcome to my crappy txt rpg.\n");
   start()
}

Last edited by AlphaXero; Feb 24th, 2005 at 9:12 PM.
AlphaXero is offline   Reply With Quote