Jumping for the ball, or leaping for a slam dunk, the human body follows the same laws of projectile motion as do other objects.
Champion Basketballer Michael Jordan seemed to hang in the air forever when he went up for a slam-dunk. Viewers would think that he is breaking some law of physics, but no, he is governed by the same laws of physics as everyone else.
How high someone can jump depends on the force he uses to push on the floor when he jumps, which in turn depends on the strength and power of the muscles of the legs. The harder and more powerfully he pushes, the higher he goes and the longer he stays in the air.
To achieve a four foot leap vertically - a jump that is very high for a basketball player - the hang time would be 1.0 seconds. Michael Jordan uses a few tricks to maximize his leaps, and make it seem longer. When he dunks he holds onto the ball for extra time than most players, and actually places it in the basket on the way down. He also pulls his legs up as the jump progresses making the jump look more impressive. All this happens in less than one second.
Physics also plays a part in free-throw technique as well. When a spinning ball bounces, it always bounces in the direction of the spin on the ball. A backspin on the ball tends to make it bounce backwards into the basket. So the ball will tend to hold up if it first hits the front of the ring, or will be directed down into the ring if it hits the backboard or back of the ring.