Allow me to restate my problem. These are the givens:
main.html
<html>
<head>
`<script type="text/javascript" src="js/MyJS.js"></script>;`
</head>
<body>
<script>
document.getElementById("DisplayVar").innerHTML = a;
</script>
<div id="DisplayVar">
</div>
</body>
<html>
MyJs.js
var a = 1;
Nothing is displayed in the "DisplayVar" div, and the developer console says that (a) is undefined. Why is this?