To solve this problem start out by making two equations....
8S+5L=184
L=S+3
the solve by substition
8S+5(S+3)=184
8S+5S+15=184
13S+15=184
13S=169
S=13
now that you know S. Fill in the S value in one of the first equations
L=S+3
L=13+3
L=16
The answer is
the small boxes cost $13
the large boxes cost $16