A senior police officer said troops of counter insurgency 29-Â Rashtriya Rifles and the Jammu and Kashmir police jointly surrounded a house in Nilah Pattan in Baramulla district early on Saturday on specific information about presence of militants inside it.
"The holed up militants of Hizbul Mujaheedin opened fire after being challenged to surrender. The fire was returned triggering an encounter at the end of which two local militants of HM were killed," the officer said.
The house in which the militants were holed up was damaged in the gunfight.
Searches are still continuing in the area. Arms and ammunition was recovered from the slain militants, he added.