To find out, you'll need to:
1. Identify your specific transmission: Look for a tag on the transmission itself. This will give you the model number. With that number, you can search online for a parts diagram.
2. Locate a parts diagram: Websites selling Ford parts (like some of the larger online auto parts stores) or sites dedicated to Ford Ranger repair often have diagrams showing the transmission and the bolts holding it together. These diagrams can tell you exactly how many bolts there are and where they are located.
3. Access to the top bolts: If there are bolts on the top of the transmission, accessing them will require dropping the transmission. There's no way to get to the top bolts without significant disassembly. You'll need to disconnect the driveshaft, shift linkage, clutch cable, and possibly the speedometer cable before removing the transmission from the vehicle.
In short: You can't know the exact number of bolts without identifying your specific transmission and consulting a parts diagram. Attempting to guess and proceed without proper information could lead to damage.