Freddy bought 3 bags of pebbles to put in his fish tank. Each bag contains 295 pebbles. After he put the right amount of pebbles in his fish tank, he had 104 pebbles left over. How many pebbles did he put in his fish tank?