The Apple ][ and its operating system were around for several years before Microsoft purchased their first operating system so no Bill didn't have an OS first. Microsoft wasn;t even considering branching out into operating systems until after several versions of Apple had been released.
Prior to IBM approaching Microsoft to produce an operating system for them after Digital Research refused to, Microsoft were in the programming language business - they invented BASIC. It was only after DR refused to supply CP/M to IBM that IBM (who had already convinced MS to give them BASIC) asked them to get them an OS as well. Paul Allen purchased QDOS from a friend of his for $50000 and they reworded it into MS/DOS1.0.
It was some time after that when Apple and Microsoft both copied the Xerox mouse.
The only operating system Microsoft has developed from scratch rather than purchasing something to base it on is OS/2 which they started developing for IBM. When MS split with IBM they both had rights to the operating system and MS renamed their version to avoid confusion and to try to cash in on the name of their graphical interface for DOS. Their OS/2 operating system is now on its seventh version.