Great Britain's water polo women were beaten 10-5 by Italy to finish bottom of their group at London 2012.
Ciara Gibson-Byrne and Alex Rutlidge brought GB back to 2-2 early on before the Italians then took control.
Francesca Painter-Snell cut the deficit to 6-3 at half-time but Italy moved 10-4 clear before Chloe Wilcox scored a penalty in the last minute.
Britain progress to the quarter-finals despite losing all three matches and will face Spain, winners of Group A.
"To be honest we are not broken," said GB's Hungarian coach Szilveszter Fekete. "We wanted to play a great match in front of our supporters, but losing to the European champions should not be regarded as a tragedy."
On the match against Spain, Fekete said: "The last time we met in Barcelona, we lost 9-7 with Spanish referees on the poolside."