How you spend the last days of your life matters.