The correct answer is B. 18.

A sucrose molecule is made up of one glucose molecule and one fructose molecule. Glucose has 6 carbon atoms, and fructose has 6 carbon atoms. Therefore, a sucrose molecule has 18 carbon atoms.

Option A is incorrect because glucose has 6 carbon atoms, not 3.

Option C is incorrect because fructose has 6 carbon atoms, not 15.

Option D is incorrect because glucose and fructose each have 6 carbon atoms, so the total number of carbon atoms in a sucrose molecule is 18, not 12.