Thisara Perera and Jeevan Mendis combined for a 58-run partnership to give Sri Lanka a nervous four-wicket victory over Afghanistan in their World Cup Pool A match.

The pair finished off what Mahela Jayawardene (100) and Angelo Mathews (44) had started after Sri Lanka had been reduced to 51 for four by the World Cup debutants as they chased 233 for victory.

Visit Al Jazeera's 2015 Cricket World Cup page for news, updates, features and comment pieces

Jayawardene had appeared to have the outcome in control for Sri Lanka with his 19th ODI century and a 126-run partnership with Mathews but when he became Hamid Hassan's third wicket with 55 runs needed, the momentum shifted back towards Afghanistan.

Perera, an aggressive lower-order batsmen, then took the game away with some big hitting and finished on 47 as his side made 236-6 with 10 balls to spare.

Afghanistan had been dismissed for 232 in 49.4 overs, which was not considered enough of a target to defend on the small University Oval ground and good pitch that tends to get easier to bat on as the day progresses.

Their bowlers, however, started like they felt it would be sufficient with both Lahiru Thirimanne and Tillakaratne Dilshan dismissed for golden ducks, while Kumar Sangakkara was bowled by Hassan for seven.

Hassan struck again in the 12th over when Dimuth Karunaratne was well caught by Nawroz Mangal at first slip for 23, which reduced the 1996 World Cup champions to 51-4.

However, Jayawaardene's effort ensured Sri Lanka registered their first points at the 2015 World Cup.

Scorecard:

Afghanistan 232 all out in 49.4 overs (Stanikzai 54, Malinga 3-41)

Sri Lanka 236-6 in 48.2 overs (Jayawardene 100, Hassan 3-45)

Source: Reuters