47 Since there are two levels of indenting in this pseudocod
Since there are two levels of indenting in this pseudocode, your finished code should contain correspondingJavaScript blocks, each of which begins with a { curly bracket and ends with a…