New to javascript and I find myself often trying one before realizing the other one is what I need, are they not doing the same thing?
Here are what I found for your questions: addEventListner:
On the other hand - onclick:
Also, you can read more about the difference Here