Single-cylinder engines are the simplest form of engine. They have just one piston and tend to be mounted either horizontally or vertically. You'll typically find single-cylinder engines in lawn mowers, scooters, and bikes because of their size and simplicity.
The most common engine is the "straight" engine. These tend to have four or six cylinders. Most cars come with a straight-four engine because they are relatively compact and offer a good potential mix of refinement, power, and economy. In some cases you may find straight engines referred to as "slant" engines, if the cylinders are mounted at an angle instead of vertically.
In an effort to make engines smoother and more powerful, more cylinders were added. It wasn't uncommon to find straight-eight engines in expensive cars from the '20s, '30s, and '40s. The major downside of big straight engines was their size, as they were typically very long.
To solve the issue of excess length, while maintaining a higher number of cylinders, the "Vee" engine was developed. Most commonly found in six, eight, 10, and 12-cylinder configuration, Vee engines have two separate sets of cylinders that are mounted in a V shape.
Some manufacturers, such as Porsche, employ "flat" engines in their cars. As you've probably guessed, this design of engine has multiple pistons that are mounted horizontally. Typically there is one set, or bank, of pistons on each side of the crankshaft. Occasionally referred to as "boxer" engines, they can be mounted low in a car which improves handling.
Lastly, some cars use what's known as a Wankel engine, which is sometimes referred to as a rotary. This differs from conventional engines as, instead of pistons moving up and down inside cylinders, it uses a rotor that spins inside a housing. Mazda is one manufacturer that has previously made extensive use of this type of engine.
Wankel engines are notable because they don't have many moving parts, they're compact, very smooth, and capable of high-speed operation without difficulty. The downside is that they're inefficient and there are issues with reliably sealing the tips of the rotor against the housing, leading to poor performance and eventual failure of the engine.
As a general rule of thumb, the more cylinders an engine has the smoother it will be and the higher its power output will be. Adding more cylinders typically increases the size, weight, and complexity of an engine, however, so there is a balance to be struck.
There are many other oddball engine layouts out there, but these are the most prevalent types, ones that you'll see in the vast majority of road cars around you.
How many cylinders does your car have and how are they arranged, or are you one of the brave types who owns a Wankel-engined car?