char is just a integer, but string. scanf is not input, you must call scanf with pointers. \n is not newline (it's \n).