how to print a list in javascript
var array = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'.split('');
for (var i = 0; i < array.length; i++) {
var str = '';
for (var j = 0; j <= i; j++) {
if (array[j] == 'E') str += '3';
else str += array[j];
}
document.querySelector('span').innerHTML = document.querySelector('span').innerHTML + str + '<br />';
}