title: Javascript Convert Hours and Minutes into Days
body: <p>I'm sorry if something similar might be discussed before, but I really need help with it. </p>
  
  <p>Bellow is the code all I want to do is if the number goes over 24h it should switch to 1 day and 0 h, I can't figure it out if someone can please explain how to do it that would be so kind. I'm using it to calculate minutes and hours and want to have also days calculations if the number is higher then 24h.</p>
  
  <p>Thanks in advance</p>
  
  <pre><code>    //minutes to hour converter
      function ConvertMinutes(num){
        h = Math.floor(num/60);
        m = num%60;
        return(h + "hours"+" :"+" "+m+"minutes").toString();
      }
  
      var input = 68.68
  
      console.log(ConvertMinutes(input));
  </code></pre>