Given an int variable k that has already been declared, use a for loop to print a single line consisting of 97 asterisks. Use no variables other than k.

Given an int  variable k that has already been declared, use a for loop to print a single line consisting of 97 asterisks. Use no variables other than k.

LANGUAGE: JAVA

CHALLENGE:

Given an int variable k that has already been declared, use a for loop to print a single line consisting of 97 asterisks. Use no variables other than k.

SOLUTION:

for(k=1;k<=97;k++){
   System.out.print("*");
}

Add comment