Try simply this
Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="generator" content="PSPad editor, www.pspad.com">
<title></title>
<style type="text/css">
body{font-family:courier,monspace;text-align:center;}
p{margin:3px;}
</style>
</head>
<body>
<h1>Pascal's Triangle</h1>
<div id="pge"></div>
<script type="text/javascript">
function co(n,p) {
if ( n<p || n<0 || p<0 ) return 0;
if ( !p || !n) return 1;
return co(n-1,p-1)+co(n-1,p);
}
var N=0;
function nxtLgn(){var i,str='';
N++;
for (i=0;i<N;i++) str+=co(N,i)+' ';
document.getElementById('pge').innerHTML+='<p>'+str+'</p>';
if (N<21) setTimeout(nxtLgn,10);
}
nxtLgn();
</script>
</body>
</html>