Python alternative to Java applet?

白昼怎懂夜的黑 提交于 2019-12-09 05:59:52

问题


Is there an alternative to making educational Java applets for physics simulations like projectile motion, gravity, etc?


回答1:


If you want it to run in a browser, you could use PyJamas - which is a Python-to-Javascript compiler and set of tools.

I'm not sure how well it is maintained these days, though.




回答2:


In this day and age, you might look to the HTML 5 canvas & JS.




回答3:


While I'm all for the "HTML5 & JS", you can consider Jython and simply write a Java Applet in Python (2.2.3, but...) Java is not only a language, so you're free to choose.




回答4:


You can run IronPython in Silverlight applications:

http://www.voidspace.org.uk/ironpython/silverlight/index.shtml




回答5:


Brython is your alternative. It allows you to define "text/python" scripts.




回答6:


You can run CPython in the browser using empythoned. There is no proper interface from Python to the browser though, so it will be hard to do any GUI applications.



来源:https://stackoverflow.com/questions/8786842/python-alternative-to-java-applet

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!