keep in mind where the ground is. If you're starting at ground level and shoot horizontally, you're never in the air so time of flight is zero.
If both of them start at some height h, then the horizontal one lands first. Your airtime is only determined by the y position and velocity.
Both of the balls started with the same energy, so neglecting air resistance, both of them should have the same energy when they hit the ground and hence the same speed, albeit in different directions. The vertical one will be going straight down and the horizontal one will be at some slant.
If you do take into account air resistance, the vertical one will have less energy. I think. At least that's what my physics gut tells me. You'd have to figure out some slick way of calculating that if you want to because I know that at least for 2-D projectile motion with drag the equations are unsolvable. At least with normal techniques.