added method to return number of years