Box Seat tickets for the baseball game cost $4 each and General admission tickets cost $3 each. If 1787 people attended the game and the total amount sold was $5792, find the number of each kind of ticket sold.