Finland edged Romania 67-63 in Eilat, Israel, to earn the fourth and final spot on offer from Group E for the Quarter-Final Round of the U18 European Championship Women Division B.
In a battle of 1-3 sides, the Finns stayed in the hunt for medals as Vilja Kesänen erupted for 23 points - nearly double her tournament average of 12.
The game wasn't decided until the very end.
With 1:32 to play, Romania's Sonia Ursu scored on a put-back to knot the contest at 63-63.
Anni Mäkitalo attempted a go-ahead shot for Finland and missed, only for her teammate Salla Ekström to grab the offensive board and score immediately for a two-point lead.
Cristina Bigica and Oana Baluta each missed potential game-tying jump shots for Romania - Baluta's coming in the waning seconds.
Finland's Vilja Kesänen then added two free-throws for the four-point win.
Portugal (3-2) had already sealed their progression to the next phase.
They finished Group E with a 66-61 win over struggling England (1-4).
Hungary had already clinched first place in Group E before their game against Slovenia on Wednesday.
Reka Balint poured in a game-high 24 points to fire Hungary to a 61-51 win.
In Group F, Greece were in the same situation as Finland before the day's play as they needed a win to advance to the Quarter-Final Round.
|Avigiel Cohen filled the stats sheet with 9 pts, 6 rbs, 5 asts, 2 stls and 1 bs as her team beat Bosnia And Herzegovina|
In another battle of 1-3 teams, Greece cruised to a fourth-place finish and sealed their passage to the next phase of the competition by beating Denmark 72-53.
For the Greeks, Anna Kavasila poured in 20 points and pulled down 12 rebounds while Ida Krogh scored 21 in defeat.
Also advancing from Group F were Israel, Germany and Bosnia and Herzegovina.
Croatia got a double-double in points and rebounds from Nina Premasunac and claimed their first win in by routing Germany (3-2), 70-44.
Premasunac had 18 points and 12 rebounds.
Israel took on Bosnia and Herzegovina in the other game and
won 65-55 to finish top of their group.
Shira Shecht led Israel with 18 points and corraled nine rebounds.