posted 14 years ago
every execution path has to return the defined type. As the previous poster wrote, when your 'if' condition is false, the compiler doesn't know what to return.
you can fix it in several ways, the easiest being something like:
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors