# Calculating the time difference in minutes and scoring depending on the answer

Hello everybody,

I am building a form to collect data and want the observer to indicate the start and end times. I want to calculate the time difference in between (in minutes) and score this as 1 if the time spent is between 45-60 minutes. If not, it will be scored as zero (all the values below 45 and above 60 minutes will be counted as 0 for quality assurance purposes).

To calculate the time difference (in minutes), I used the formula below (I hope that this will give the total minutes directly):
\${time_end} - \${time_start}
However, I cannot figure out how to grade this accordingly if between 45 and 60 minutes as 1. I used the formula below, but gives an error when I want to deploy the form:
if(\${time_total}=45:60,1,0)

I appreciate it if anyone has any ideas or knows the appropriate calculation for this.

Many thanks!!!

Welcome to the community, @selinturan! You could use the `if-statement` as outlined in the post discussed previously: