text: let hr = document.querySelector('#hr');
  let mn = document.querySelector('#mn');
  let sec = document.querySelector('#sec');
  
  setInterval(() =>{
      let day = new Date();
      let hh = day.getHours() * 30;
      let mm = day.getMinutes() * 6;
      let ss = day.getSeconds() * 6;
      
      hr.style.transform = `rotateZ(${hh+(mm/12)}deg)`;
      mn.style.transform = `rotateZ(${mm}deg)`;
      sec.style.transform = `rotateZ(${ss}deg)`;
  
      // div time
      let hour = document.getElementById('hour');
      let minutes = document.getElementById('minutes');
      let seconds = document.getElementById('seconds');
      let ampm = document.getElementById('ampm');
  
      let h = new Date().getHours();
      let m = new Date().getMinutes();
      let s = new Date().getSeconds();
      let am = h>= 12? "PM" : "AM";
  
      hour.innerHTML = h;
      minutes.innerHTML = m;
      seconds.innerHTML = s;
      ampm.innerHTML = am;
  
      h = (h<10) ? "0" + h : h
      m = (m<10) ? "0" + m : m
      s = (s<10) ? "0" + s : s
  
      // convert 24hr clock to 12hr
      if (h>12){
          h = h-12;
      }
  })