President Obama said he should have known better than to go golfing immediately after speaking about the beheading of an American journalist.