Plantains are members of the banana family, and as such are fruits, not vegetables.  Unlike bananas, however, plantains are starchy and must be cooked before they can be eaten.  As plantains ripen, their starch converts to natural sugar and they become sweet.  You can gauge the ripeness of plantains by the color of their skin;  green plantains are unripe, yellow are at an early stage of ripeness, and black plantains are fully ripe.  If the plantains you purchased at the market are a dull yellow with brown patches, and your recipe calls for ripe plantains, it may take a week or so sitting on your kitchen counter to render them completely black and utterly ripe.

There are recipes for plantains at every stage of ripeness.  Plantains are served, fried, with almost any meat or fish dish in the Caribbean islands, though with some dishes, such as Cuban picadillo, they are traditional.  They usually are treated as vegetable side dishes, not unlike potatoes, although in Guadeloupe they may be sprinkled with sugar after they are fried, then flamed with rhum vieux and served as a dessert. 

If plantains are not available and you wish to use bananas as a substitute, use them when they are ripe, but still firm and the skins yellow, not black.