Let x be the number of cans bought and y the number of brush bought.
He spent $25 on each can, so $25x per x cans.
He spent $12.75 on each brush, so $12.75y on y brushes.
In total, he spent $327.
From those information, we can get the equation:
25x + 12.75y = 327.
Hope this helps! :D