In deck_shuffle() it should be:
for (int i = 51; i > 0; --i)