Q:

Does it take more energy to get to Venus or to Mars?

Let's assume we use the ideal positions of those planets relative to Earth for launch. And let's assume the spacecraft is launched from the same place on Earth. Also let's assume the goal is to get the same mass of payload to those planets, meaning the launch vehicle could be different, depending on the energy requirements.   
"Getting to" could possibly be a bit imprecise, so let's define it as meaning directly impacting the surface with the spacecraft.  
Alternatively, does anything change if "getting to" means getting into orbit around those planets?

A:

To flyby or impact Venus varies from 3.45 to 3.6 km/s from LEO for the optimal time every 19 months. Mars varies from 3.55 to 3.9 km/s for the optimal time every 26 months. So on average, getting to Venus is a little less energy than getting Mars. But not by much. It could even be a tiny bit more in some years.
If you also want to get barely into orbit propulsively, the ranges are 4 to 4.7 km/s for Venus and 4.25 to 7 km/s for Mars.
Mars is more variable than Venus due to its much larger solar orbit eccentricity (0.09 vs. 0.007).
At either planet, you can aerobrake down to the desired orbit. Aerobraking has been demonstrated at both. Or you can aerocapture directly, with just the flyby costs above. Aerocapture has never been demonstrated, but there are no hurdles that would prevent its use in a mission, other than developing an adequate heatshield for Venus (much higher entry velocity). However you incur the substantial mass penalty of the aeroshell, a cruise stage that is discarded before entry, and the structure and mechanisms to discard the aeroshell and deploy the enclosed spacecraft. Aerocapture at neither body appears to be a win if you can afford the time to aerobrake, measured in months. (Aerocapture is mission enabling at Uranus, Neptune, and Titan.)

A:

The second table here essentially answers your question. Venus transfer from Low Earth Orbit is 3.5 km/s, Mars transfer is 3.6. 
This will allow you to impact either body (on Venus you will need to make sure your vehicle is tough enough to actually impact, rather than dissolving in the atmosphere, but that's not really the point).
In either case, you can enter orbit for negligible extra energy, but some risk, by aerocapture. Basically you graze the upper atmosphere, losing just enough velocity relative to the planet to enter a long elliptical orbit. At the highest point of that orbit you make a very small boost to raise the lowest point of the orbit to graze the atmosphere even more gently, and then repeated encounters will lower the high point of the orbit. When it's where you want it, you make a further small correction to miss the atmosphere entirely and you are there.

