How to run python program in IOS Swift app How to run python program in IOS Swift app xcode xcode

How to run python program in IOS Swift app


This tutorial seems to be fairly clear and easy to follow, and cover the necessary steps. Is there any chance you could share what the algorithm in question is? It might make more sense to use C - it looks like you can mix Obj-C with Swift. That said, I am not confident that you can actually do this on iOS.

First of all, your app might not get through App Store review if it has an executable for Python in it. Apple has its own docs on embedding Python in OSX/Mac OS apps, but not for iOS.

Additionally, I don't think an official executable of Python for iOS even exists. The closest thing I could think of, or find, is Pythonista, but I believe the developer made their own version of Python for iOS.

It looks like you can export Pythonista code to stand-alone apps, although how useful this is, and weather or not you can do this for iOS, I don't know. Additionally, that feature only works with Python2. Hope this helps.