Python Write Function Output Js