is it compulsory to write int width in the first while loop and not in the starting if yes then why?
package en.codegym.task.pro.task04.task0404;
/*
Filled rectangle
*/
public class Solution {
public static void main(String[] args) {
//write your code here
int height = 0;
int width = 0;
while (height < 5){
while (width < 10){
System.out.print("Q");
width++;}
System.out.println();
height++;}
}
}