Cooking steak is a joy, because it is a terrific piece of meat with great flavor, whether grilled or fried. There are no rules, apart from this: Eat the steak cooked the way you like it and tell steak snobs to back off.
I suggest frying the more delicate steaks such as filet mignon and grilling the bigger, tastier, fattier ones like the rib-eye or anything on a bone, such as porterhouse or T-bone.
It is hard to say how long to cook a steak, because each one varies in thickness and structure. But generally, for medium steak, I'd sear for 2 minutes on each side, then cook a minute extra for each 3/8 inch or so of thickness. So a 3/4-inch-thick sirloin served medium will take about 6 minutes in total. If there is a bone, it will be more like 2 minutes extra per 3/8 inch.
Use a solid pan that will hold the heat well, nothing flimsy. A black cast-iron skillet is perfect. Start by heating the skillet really well. If your steak is very thick (2-3 inches), heat the oven too, to 400 degrees, for finishing the cooking. Rub the steak with ample oil — vegetable oil is best. Season with salt and pepper after it is covered with oil or the salt will start to eat into the meat and dry it out.
If the steak is thick, put the pan in the oven. Cook for about 4 minutes, depending on the desired degree of doneness. You won't ever need to leave it in the oven for more than about 8 minutes; if you do it will be cremated.
Take the steak out and let it rest for 5 minutes — remember that the steak will continue to cook while it is resting. Drop a generous blob of butter in the pan before you set it aside. Pour the mix of melted butter and meat juices over the steak when you serve it.
Use a ridged cast-iron grill pan (also called a skillet grill or broiler pan).
Set it over high heat 10 minutes before you even think about cooking. Meanwhile, rub the steak with oil and season it with salt and pepper on both sides.
Lay the steak on the grill pan and leave it for 2 minutes, then flip and sear the other side for 2 minutes. Continue cooking to the desired degree of doneness, then remove the steak and let it rest. As with the fried steak, if it is really thick, finish the cooking in the oven, still in the grill pan.