If the reaction takes place in presence of sunlight ,

CH3CH2CH3 + Cl2 gives CH3CH2CH2Cl &CH3CHClCH3

In this second compound is major product with 2° C atom attached chlorine BUT ,

In this reaction ,

CH3CH(CH3)CH3 + Cl2 gives CH3CH(CH3)CH2Cl & CH3C(CH3)(Cl)CH3

In this first compound is major product .

Why ? I cannot understand why major product changes even though reaction mechanism is same.