reset input parameters to its initial state

Back to General discussions forum

cankayabebesi     2017-08-22 10:12:31

Hello, is it possible to reset the input parameter to its initial state ( something like reset() )? since i'm working with javascript in chrome console, everytime i get the input parameters with input() method, it is not possible to reset the parameters to its initial state. i keep reloading the web page to get over this problem. Thanks in advance.

Quandray     2017-08-22 10:51:57
User avatar

I tried doing what it says at the bottom of http://www.codeabbey.com/index/wiki/running and that worked ok for me.

cankayabebesi     2017-08-22 13:13:17

input and output methods work fine in console. but my problem is that after calling input method several times to test my function, how can i read the first line of the input() again? without needing of reloading the browser is there any method like reset to reset the input to its initial state so that when i call input again, it will read the first line again, then next line, then next...

Quandray     2017-08-22 18:42:33
User avatar

Sorry, I don't use Javascript, so this probably won't be of much help. Using Firefox, if I go to the Sum of Two page, and put

var s = input().split(' ');
output(parseInt(s[0]) + parseInt(s[1]));

in the Your Solution box, then I can run it using the Javascript button many times without reloading the screen.

Please login and solve 5 problems to be able to post at forum