I want to develope for iOS and Android using Cocos2d-x or Unity 3d. From what I've heard, you will need a computer running mac OS to legally get your app in the app store. The problem is that apple computers are horribly overpriced and I'm on a budget so I can't afford to get a mac. I want a computer that is fast and the only mac that fits my requirements is the Imac, which costs around $1500 dollars and I can't afford that, considering I'm only 14. I could build a better computer than that for only $700, not to mention I could upgrade it later down the rode.
What my question is, is if it's possible for me to develope on a windows computer using Cocos2d-x or Unity 3d, and then transfer my code to a mac mini (maybe like a cheap used one that costs like $400) and then will i be able to legally put my app on the app store? I haven't worked with a game engine before so I don't know if this is possible or not. Thanks