Forum Discussion

LL19911695's avatar
LL19911695
Copper Contributor
Jun 22, 2022
Solved

Removing decimals in a MOD formula

I am trying to create a formula which returns the average length of time in years and months from a data set.    In column Z of my dataset I have lengths of time in months. In a new cell on a sep...
  • Riny_van_Eekelen's avatar
    Jun 22, 2022

    LL19911695 Like this perhaps?

    =INT(B6/12) & " years and " & TEXT(MOD(B6,12),"0") & " months"

     

    Alternatively:

    =INT(B6/12) & " years and " & ROUND(MOD(B6,12),0) & " months"

     

Resources