How do I accept a variable from the console with javascript in Rhino? anything similar to cin or scanf?
Here's two lines that'll do what you want:
var stdin = new BufferedReader( new InputStreamReader(System['in']) ) var aLine = stdin.readLine();