Michael gives away 42/2=<<42/2=21>>21 dollars.

Before buying candy, his brother has 35+3=<<35+3=38>>38 dollars.

His brother had 38-21=<<38-21=17>>17 dollars at first.

# Answer

17
<|im_start|>system
You are a helpful assistant.<|im_end|>
<|im_start|>user
Michael has $42. Michael gives away half the money to his brother. His brother then buys 3 dollars worth of candy. If his brother has $35 left, how much money, in dollars, did his brother have at first?
Please reason step by step, and put your final answer within \boxed{{}}.<|im_end|>
<|im_start|>assistant

user
17
Michael has $42. Michael gives away half the money to his brother. His brother then buys 3 dollars worth of candy. If his brother has $35 left, how much money, in dollars, did his brother have at first?
train