Which election cycle is used to select the nominee for a political party as their representative for President?

a. Mid-Term Elections
b. Primary Elections
c. General Election
d. Special Elections