Let x be the number of dollars my brother has. Since we will have the same amount of money if I give him 5 dollars, I must have x + 10 dollars. (Make sure you see why I don't have x + 5 dollars. If I give him 5 dollars of my x + 10 dollars, then we will both have x + 5 dollars.)
If he gives me 17 dollars, then he will have x - 17 dollars and I will have x + 10 + 17 = x + 27 dollars. I'll then have twice as much money as he has, so
x + 27 = 2(x - 17) Expanding the right-hand side gives x + 27 = 2x - 34, so x = 61. So, my brother has $61, and I have $71