Q:

javascript not working, am i missing anything?

I was following Devslopes tutorial on making the navbar responsive and i reached a point where i got stuck. in his video, after writing the javascript code and mediaquery css his navbar is showing but mine is not and i did exactly the same.
tutorial video link
html code:  
<html lang="en">
<head>
    <title>Document</title>
    <link rel="stylesheet" href="style.css">
</head>

<body>
    <nav>
        <ul class="topnav" id="dropdownClick">
            <li><a href="#home">Home</a></li>
            <li><a href="#news">News</a></li>
            <li><a href="#contact">Contact</a></li>
            <li><a href="#about">About</a></li>
            <li class="topnav-right"><a href="#signup">Sign-Up</a></li>
            <li class="topnav-right"><a href="#signin">Sign-In</a></li>
            <li class="dropdownIcon"><a href="javascript:void(0);"  onclick="dropdownMenu()">&#9776;</a></li>
        </ul>
    </nav>  

    <script>
        function dropdownMenu(){
            var x = document.getElementById(dropdownClick);
            if(x.className === "topnav"){
                x.className += " responsive";
                // change topnav to topnav.responsive
            } else{
                x.className = "topnav";
            }
        }
    </script>

</body>
</html>

Css Code: 
/* *****   defaults   ******** */
nav,
header,
footer{
    display: block;
}

body{
    line-height: 1;
    margin: 0;
    padding: 0;
}

/* ******   Navbar   ***********/

nav{
    width: 100%;
    margin: 0;
}

nav ul{
    background-color: #eee;
    overflow: hidden;
    margin: 0;
    padding: 0;
}

ul.topnav li{
    list-style: none;
    float: left;
}

ul.topnav li.topnav-right{
    float: right;

}

ul.topnav li a{
    display: block;
    text-decoration: none;
    min-height: 16px;
    text-align: center;
    padding: 14px;
    text-transform: uppercase;
    color: #666;
}

ul.topnav li a:hover{
    background-color: #0088ff;
    color: #fff;
}

ul.topnav li.dropdownIcon{
    display: none;

}

/* ************  mobile  ******************** */
@media screen and (max-width: 680px){
    ul.topnav li:not(:nth-child(1)){
        display: none;
    }

    ul.topnav li.dropdownIcon{
        display: block;
        float: right;
    }

    ul.topnav.responsive{
        position: relative;
    }

    ul.topnav.responsive li{
        display: inline;
        float: none;
    }

    ul.topnav.responsive li a{
        display: block;
        text-align: left;
    }
}

Thank you.

A:

In var x = document.getElementById(dropdownClick); the element ID (dropdownClick) is a string and should be in quotes like var x = document.getElementById('dropdownClick');

