Star Pattern In Javascript Using While Loop