1
How to make a Javascript program that takes two positive numbers and repeats the interval between them using while
?
var num1 = Number(window.prompt("Entre com primeiro numero"));
var num2 = Number(window.prompt("Entre com segundo numero"));
var numero = 0;
if( num1 >=0 && num2 >=0){
while (numero>= num1 && numero >=num2){
document.write (numero+" ");
numero++;
}
}
What is repeating the interval between them? Repeating what? Is the interval inclusive or exclusive? On both sides?
– Maniero
The answers helped you solve the problem?
– Sergio
See [tour]. You would help the community by identifying the best solution for you. You can only accept one of them, but you can vote for any question or answer you find useful on the entire site (if you have enough punctuation at the time).
– Maniero