Sweden produced the regulation victory they needed in Group B, while Slovakia finished fifth despite a strong opening phase.