South Africa is a parliamentary democracy. Based on this information, how is the president of South Africa determined?
A. Whoever controls the South African military becomes the president.
B. The legislature of South Africa votes to elect the president.
C. Whoever controls the South African courts becomes the president.
D. The citizens of South Africa vote directly for the president.