If the cable snapped so that it can be seen from the cabin, try to pick up its interior (not braid) with a pair of pliers and pull, trying to open the lock. This method is the simplest, but not always it turns out that the cord ends this way.
If the cable was broken right under the hood, you can reach it directly from the salon is a bit trickier. For this you need to get directly to the hood lock from the bottom of the machine. So get the car on a viewing hole or overpass so that you had free access to the space under the hood. Take the two keys and remove the protection crankcase.
Can also try another way: remove the left headlight of the car (while moving) and get access to the hood lock. Here you should not have problems with opening it manually. Of course, this option is not very convenient when you need to open the hood, for example, to request traffic wardens. However, this is easier to accomplish than previous versions.
In some hoods, BMW has a intermediate cable that can be accessed by removing the headlights. Note that the lights can not be seen. So, take a screwdriver or bent rod and use it to find an intermediate cable. Pull it and the bonnet will open. If castle or two, then this procedure should be carried out in both headlamps.
Remove the front fasteners bellow of the engine and fold it down. Try to get my hand to the bonnet next to the radiator. If the hand does not fit, push the screwdriver in there and push hard on the left side facing the car on the latch of the hood. If you did everything correctly, the lock will open.
To reduce the likelihood of breakage of a cable, regularly lubricate with silicone grease the lock mechanism of the hood. Sometimes spray it inside the braid of the cable to maintain good mobility.