In a warehouse, there are two types of boxes: type X and type Y. The total number of boxes is 1200. Out of these, 3/4 of the boxes are type X, and the remaining boxes are type Y. Additionally, the difference between the number of type X boxes and type Y boxes is 240.