A woman has a total of $ 9,000 to invest. She invests part of the money in an account that pays 11 % per year and the rest in an account that pays 12 % per year. If the interest earned in the first year is $ 1040, how much did she invest in each account?