function ShowSub(li) {
var subMenu = li.getElementsByTagName("ul")[0] ;
subMenu.style.display = " block ";
}
<li onmouseover="ShowSub(this)" onmouseout="HideSub(this)" ><a href="#">课程大厅</a>