The horizontal speed has no effect on how long it flies before it hits the ground ... only how far it goes horizontally before it hits the ground.
Rock A and rock B will hit the ground at the same time. (C) BUT ... Rock-B had more horizontal speed, so it'll go farther before it hits the ground.
Weirdly ... that means that if you aim a gun horizontally, and drop a bullet from the muzzle at exactly the same time as you shoot the gun, both bullets will hit the ground at the same time.