kmdv's observation is on the mark, but a few other things to watch out for:
  • wordbank is an array of 100 words, but your loop that reads into wordbank does not check for this, thus your program is susceptible to buffer overflow.
  • getword probably should return a bool instead of an int.
  • While reading into wordbank, you increment i. Thus, when the loop terminates, you know the number of words that have been stored. Use this knowledge instead of testing with wordbank[i].empty().
  • As a matter of good style, include the parameter name in your forward declaration of getword. Personally, I would rather forward declare getword at file scope rather than in the scope of main.