I can't get my javascript to work

I using Vs.code and i can’t get it to work. I put in in js fiddle to see if it would work there. I do understand js please help me.

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.130 Safari/537.36.

Challenge: Build a JavaScript Calculator

Link to the challenge:

Try change this

$(“key-pad”)

to this:

$(" . key-pad")

There are other errors but this will let you at least see the effect on your screen (the correct version will select the class, if i am not mistaken right now you are looking for a non-existent key-pad tag)^^

i make so many typing errors on my pages i wish there was an editor for that.

there are some validators you can use, maybe even in jsfiddle but I don’t know that application

I got my input to work but now my keys lined up on the left i wish i could show it to you but i’m in vs.code and I don’t how to get the link.
can anyone help.

If you are going to use VS Code to edit your project, I strongly suggest watching a few tutorials on the basics of Git and GitHub. This will allow you to post your code to GitHub and provide a link to us.

What do you mean by “get the link”?

I will take that suggest

I got my files in git hub now how do i show it to you

maybe this will work?

ok got that fix. my input is working but how do i get the it to return to o.
when i press ac.

ok, now the zero stays when I press other numbers. I feel so overwhelmed. EX. (07890)

also my git hub isn’t updating. What a mess!

git updated now //////

      //If you press delete clear the inputs and update. 
      if(this.id==="clear") {
        inputs=[""]; 
        update(); 
      }

When your page first loads, there is a “0” in the element with id=“display”. Why not set the html/text of this same element back to “0” when the AC button is clicked.

didn’t work
inputs= document.getElementById("display").innerHTML;

what if i just fork one is that illegal.

inputs needs to stay an array for everything else to work in your code. You can add a single line after the update() line to set display to 0.

i may have to start over again im not understanding

How can you set the html value of the element with id=“display” to 0? You already know how to do this, because another function you wrote does something similar.

Man it was right in front of me