Group Formation, In-group Bias and the Cost of Cheating