James is x years old, the sum of him and his brother's age is 10.

3 years ago, James brother was three times older than James. Use this to write an equation