0

I need to show the code just like i have shown through my code as you can see. I want to draw the picture in the code. but the line break is not working. the output is showing all the things in a line.

console.log(document.write('  ******\n'))
console.log(document.write('   ****\n'))
console.log(document.write('    **\n'))
console.log(document.write('   ****\n'))
console.log(document.write('  ******\n'))
console.log(document.write(' ********\n'))
console.log(document.write('**********\n'))
CertainPerformance
  • 356,069
  • 52
  • 309
  • 320
Maisha Maliha
  • 69
  • 1
  • 1
  • 8

1 Answers1

-1

console.log(document.write('  ******<br/>'))
console.log(document.write('   ****<br/>'))
console.log(document.write('    **<br/>'))
console.log(document.write('   ****<br/>'))
console.log(document.write('  ******<br/>'))
console.log(document.write(' ********<br/>'))
console.log(document.write('**********<br/>'))
Abdulla Thanseeh
  • 9,438
  • 3
  • 11
  • 17
  • 2
    Please don't answer duplicate questions; it makes it harder to remove them. This answer is essentially the same as the advice given in the answers to the duplicate. – Heretic Monkey Apr 29 '19 at 11:18
  • okay..sure i will do it – Abdulla Thanseeh Apr 29 '19 at 11:20
  • 1
    my question is not duplicate Mister. yes the answer could have been found there but I was not understanding thus I asked my own particular problem related question. so you better stop unnecessarily making my questions duplicate. – Maisha Maliha May 04 '19 at 11:01