Britain has won the first gold medal of the track cycling programme in the men's team sprint at the Beijing Olympics.