Aljazeera's correspondent in Iraq's Kurdistan, Ahmad al-Zawiti, said the bombing on Wednesday damaged the building where students of Salah al-Din University live, in the Sidawa neighbourhood.
He said the building and other nearby houses were set ablaze, adding that some nearby cars were also damaged.
Four students were injured in the two-hour-long strike, officials said. The attack came after a US helicopter had come under fire from the same area, witnesses said.
Meanwhile, a car bomb exploded in Baghdad's western district of Amiriya, killing two people and wounding 10, police officials said.
Fighters are launching a wave
of attacks ahead of planned polls
The car was following a convoy of US and Iraqi troops when it exploded near a petrol station, the officials said on condition of anonymity. All the casualties were Iraqi civilians.
The explosion came a day after armed fighters killed the governor of Baghdad and six of his bodyguards, and a truck bomber killed 10 people at an interior ministry commando headquarters, the latest in a string of violence ahead of landmark elections on 30 January.
Separately, an American soldier was killed and two others were wounded when their patrol came under fire in northern Iraq, the US military said on Wednesday.
It said armed fighters attacked the patrol with guns and rocket-propelled grenades in Talafar, near the northern city of Mosul, at about 2pm (1100GMT) on Tuesday.
Five other US servicemen died in three separate attacks on Tuesday, making it the deadliest day for the US military in Iraq since the bombing at a mess tent in Mosul on 21 December, which killed 22 people, including 14 US soldiers and three American contractors.
Also on Wednesday, an Iraqi man was killed during an exchange of fire in central Ramadi city after a US military patrol came under rocket-propelled grenade and machine gun attacks by unidentified fighters, Aljazeera learned.
US forces have taken up rooftop positions on some buildings in the city.