If a protostar contains the mass of our Sun, or less, it undergoes a proton-proton chain reaction to convert hydrogen to helium. But if the star has about 1.3 times the mass of the Sun, it undergoes a carbon-nitrogen-oxygen cycle to convert hydrogen to helium. How long this newly formed star will last depends on its mass and how quickly it consumes hydrogen.