Michael and Arish had a total of 496 collectible cards. Michael gave 1/3 of his collectible cards to Arish. Arish then gave 1/5 of his cards to Michael. In the end, they both had the same number of collectible cards. How many collectible cards did Michael have at first?

m+a = 496

2/3 m + 1/5 (a + 1/3 m) = 4/5 (a + 1/3 m)
m = 279