Optimism can be relearnt.