How long should I cook a steak to make it medium rare?
This is a 'how long is a piece of string' question. The thickness of the meat, the thickness and material of the pan, your hob type and various other factors will all influence the cooking time. So it is impossible to give you a hard and fast answer.

The best solution is to simply remove time from the equation altogether. Invest in a quick read digital probe thermometer and measure the temperature! You want the steak to be 55-57C in the middle for medium rare. It will keep cooking while it rests, so take the steak off the heat when it hits about 53-54.