In general, the theory of decision-making under uncertainty suggests maximizing an expected value, such as expected profit (theory of the firm), expected utility (theory of the consumer), or likelihood (maximum likelihood estimation in statistics).
In betting where you either win a prize or you don't, if two events have the same value prize, we can simplify to betting on the highest probability.
Here we have events A, A', and B where:
The student must bet on more red marbles urn ("red") or more blue marbles urn ("blue"). He bets on "red" when he sees red if P[A|B] > 1/2. (Since the urn is known to be either "red" or "blue", in that case P[A'|B] < 1/2, so "red" has higher probability.)