SUB-MENU NAVIGATION WITH DROPDOWN
Run
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>HTML</title>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<style>
   .navbar {
      overflow: hidden;
	  background-color: #215612;
	  width: 100%;
	 
   }
   .navbar a {
      float: left;
	  text-decoration: none;
	  font-size: 15px;
	  color: white;
	  text-align: center;
	  padding: 15px 16px;
	  
   }
   .sub-menu {
      float: left;
	  overflow: hidden;
	}
  
	  
   .sub-menu .btn {
      font-size: 16px;  
	  outline: none;
	  color: white;
	  padding: 14px 16px;
	  background-color: inherit;
	  font-family: inherit;
	  margin: 0;
	  border: none;
		  
   }
   .navbar a:hover, .sub-menu:hover, .btn  {
      background-color: black;
   }
   .content {
	  display: none;
	  position: absolute;
	  background-color: #f9f9f9;
	  min-width: 160px;
	  box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
	  z-index: 1;
	  
	}

	.content a {
	  float: none;
	  color: black;
	  padding: 12px 16px;
	  text-decoration: none;
	  display: block;
	  text-align: left;
	}
	}

	.content a:hover {
	  background-color: #eee;
	  color: black;
	}

	.sub-menu:hover .content {
	  display: block;
	}

</style>
</head>
<body>
    <div class="navbar">
	   <a href="#"> Home </a>
	   <div class="sub-menu">
	     <button class="btn">Course <i class="fa fa-caret-down"></i></button>
		 <div class="content">
		    <a href="#"> C++ </a>
			<a href="#"> Java </a>
			<a href="#"> HTML </a>
		 </div>
	   </div>
	   <div class="sub-menu">
	     <button class="btn">Study material <i class="fa fa-caret-down"></i></button>
		 <div class="content">
		    <a href="#"> Notes </a>
			<a href="#"> Answers </a>
			<a href="#"> MCQ </a>
		 </div>
	   </div>
	   <a href="#"> Contact </a>
	</div>
</body>
</html>