Finding the difference in days between dates

I’ve created a list of dates using an array aggregator. I want to automatically calculate the difference in days between the most recent date and the oldest date. I then want to be able to take this number of update a column in airtable with the number it’s calculated. I just can’t seem to get the calculation of the dates to work. it always comes back either empty or with an error message.