Automatically clear history when the app is closed

@Darktonian

Clear History exercise completed.