i used toggle for changing icon from icon(-) to this icon(+). but i stuck in the problem how to change icon(+) to this(-) when i click on another icon.
const icn = document.querySelectorAll("span");
icn.forEach(icons => {
  icons.addEventListener("click", function(e) {
    e.preventDefault()
    // console.log(e.currentTarget.classList)
    e.currentTarget.classList.toggle("fa-times");
    if (e.currentTarget.classList.contains("fa-times")) {
      // document.querySelector(".answer").style.display="flex"
    } else {
      document.querySelector(".answer").style.display = "none"
    }
  });
});<div class="question-container">
  <div class="question">
    <h2>Do You Like fruits?</h2>
    <div class="questionIcn">
      <span class="fas fa-check icn"></span>
    </div>
  </div>
</div>
<div class="question-container">
  <div class="question">
    <h2>Do You Like vegetable?</h2>
    <div class="questionIcn">
      <span class="fas fa-check icn"></span>
    </div>
  </div>
</div>
<div class="question-container">
  <div class="question">
    <h2>Do you like gaming?</h2>
    <div class="questionIcn">
      <span class="fas fa-check"></span>
    </div>
  </div>
</div>
</div>i don't know about any other language like jquery . i want to do this by using simple js because i m a begginer and it's my project.
 
     
     
    