how can i repeat this .java program again again on decoder app please do code and help me
import java.util.Scanner;
class table
{
public static void main (String args [])
{
Scanner in = new Scanner (System.in);
System.out.println ("Enter the number");
long m,i;
m = in.nextLong();
for (i=1;i<=10;i++)
{
System.out.println (m+" x "+i+" = "+m*i);
}
{
System.out.println ("THANKS FOR USING");
}
}
}
Answers
Answered by
0
Answer:
If you want to do it forever you can use while(true). CHECK MY CODE
package newPack;
import java.util.Scanner;
public class table {
public static void main(String[] args) {
Scanner in = new Scanner(System.in);
while(true) {
System.out.println ("Enter the number");
long m,i;
m = in.nextLong();
for (i=1;i<=10;i++)
{
System.out.println (m+" x "+i+" = "+m*i);
}
System.out.println("THANKS FOR USING");
System.out.println();
}
}
}
Explanation:
BRAINLIEST!
Similar questions