For a Pjs solution, given Pjs is just another JS library, we can use any language which transpiles to JS.
And among those, CoffeeScript is a mix of Ruby + Python syntax: CoffeeScript.org
Here’s a Pjs sketch I re-wrote in CoffeeScript syntax as an experiment:
GoSubRoutine.GitHub.io/Ball-in-the-Chamber/pjs-cs/