And since iOS is based on Mac, and there is an Office for Mac, I don't think they had to start 100% from scratch.
Well, it doesn't exactly work that way - you can't just write a few lines and turn a Mac App into an iOS app. Just because they use some of the same frameworks doesn't mean they can run the same apps.
They may have had to write it from scratch for iOS, but they had references with Office for Mac and Windows, so it's not like they were doing the whole thing from scratch.
It may have taken an indie developer or a team of a few people four years to write it, but a software company with enough employees to fill a stadium? No.