Before entering the courtyard, you can hear the chanting of young voices:
"A, double-P, L, E, apple... B, A, double-L, ball."
On a verandah shaded by guava trees, 35 children crane their necks to see the ABC on a rickety home-made blackboard.
The pupils sit barefoot and cross-legged, writing slates balanced on their laps. On the grass, the children's plastic flip-flops are neatly lined up on the steps below.
Nervously adjusting her pink shalwar khameez, the traditional long shirt over trousers, Nazia, the teacher, is just 15. But she is already one of the most valued members of her small community.
Deep in Pakistan's North-west Frontier Province, Kagazai is only reachable along bumpy roads cut out of the rock face of tall, craggy mountains. Far from the big cities and their relative riches, the village is like many others in this area near the Afghan border. It has no doctor, no clean water supply, and until June had no school.
This is not rare. Only 48 per cent of girls and 58 per cent of boys in Pakistan go to school. Of those, half drop out before completing the five years of primary education. Among school-leavers, only 18 per cent are numerate and 7 per cent are literate, according to government standards.
There are not enough schools within travelling distance of villages such as Kagazai and the situation is worse for girls because cultural norms in this conservative region dictate that they are not allowed to travel as far as boys to reach school.
United Nations statistics show that when students who are repeating a year, or are over-age, are considered there is a 43 per cent difference in the number of boys and girls at school in Pakistan, the joint worst gender gap in the world, along with Yemen.
Four months ago, the province's governor, former-Lieutenant General Syed Iftikhar Hussain Shah, arrived in Kagazai with a proposal. He pledged to open a no-fees school if the village provided a teaching space and employed female teachers as a way to empower women.
"I personally feel that not only do women have to be educated, they have to be brought from their homes and given jobs to become economically emancipated," he said. Although most of the parents had received no education themselves, they appreciated the difference it could make to their children's lives and did not hesitate.
Sohail Bangash, one of the village's few educated women, stepped forward to run the school from her house, offering the verandah and a room where another 35 children are taught. Her daughters, Nazia and Rohina, teach maths, English and Urdu. "There was almost no literacy here, but the future is starting to look better now," Ms Bangash said.
Although Governor Iftikhar is titular head of the province, he has no jurisdiction over education. He decided to found the Basic Education and Skill Development Trust, with his wife Shamim Iftikhar, to provide schools in isolated areas and to raise literacy among girls in particular.
"When we looked at the data, we realised that it was not girls dropping out of the system themselves, they were being pushed out," he said. In the past three months they have set up 20 co-ed schools.
While not willing to criticise the present government, the governor concedes years of corruption and underfunding and political instability have brought the national education system to its knees.
With half of the 142 million population under 18, the pressure on the ailing system has reached crisis point. Religious and philanthropic organisations like his trust can only patch holes in it.
Teenage teacher Nazia thinks her pupils are among the lucky ones. "We're very proud of the school and think it's a very good project," she said.
"After the school started, the children became better disciplined - good kids."