Originally Posted by
whiteflags
But that's not even the worst of it. The variable searchtitle isn't defined yet, but I can guess what it should be. &searchtitle is a completely different kind of argument to scanf. You're pointing to a string (char **, not what I would guess as the correct type, char *). As you found out in class I hope the name of an array decays to a pointer to the first element in pointer context.
Arrays are frequently used in pointer context, so it's important to know you need that extra star or &.
If the call were like this:
scanf ("%s" , searchtitle);
It would work to an extent. You'd be vulnerable to a user typing too long of a title, but I see you know what field widths are, from your other bits of code.