Skip to content

Instantly share code, notes, and snippets.

@tdouce
Created March 12, 2010 15:55
Show Gist options
  • Save tdouce/330458 to your computer and use it in GitHub Desktop.
Save tdouce/330458 to your computer and use it in GitHub Desktop.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script type='text/javascript'>
function print(msg,x){
document.write(msg,"<br/>");
}
function range(upto) {
var result = [];
for (var i = 0; i <= upto; i++)
result[i] = i; /* What does this line of code do? */
return result;
}
print(range(4));
</script>
</head>
<body>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment