Coping saws are handsaws used for intricate woodworking. They look like large Cs with a handle coming off one end. A thin metal blade stretches across the open end of the C. While coping saws can be used to cut shapes out of wooden objects, their original purpose -- and the source of their name -- comes from their ability to create a cope. A cope is the way that the ends of various moldings are joined together in an almost seamless manner.
If you need to trim molding or baseboard to the right length so that it fits your wall, your best bet is using a coping saw so that the baseboards are flush with each other in the corner. The idea behind a coped joint is that instead of cutting straight, you cut the end of one piece of baseboard or molding to fit like a puzzle over the profile of the other piece. You might want to practice before you attack your actual project, since creating a tight cope joint is a skill gained through a lot of practice.
One of the ends of the baseboards that meet in the corner can be cut straight so it lines up with the wall. For the coped side of the baseboard, trace a line on its back using the other baseboard as a guide. Then use your coping saw to cut along that line. The smartest way to go about it -- especially if you're new to using a coping saw -- is to not cut exactly on the line. Instead, leave about a millimeter or so of extra room to be safe. Then after you've checked your cut against the other piece of baseboard, you can finish off your cut in the right place.