Learning on the Job and the Cost of Business Cycles