To solve the problem, we can set up a system of equations based on the information provided.
Let \( p \) be the number of peaches sold and \( q \) be the number of pears sold. We have the following two equations:
-
The total number of fruits sold: \[ p + q = 15 \]
-
The total revenue collected: \[ 3p + 2q = 40 \]
Now, we can solve this system of equations step by step.
From the first equation, solve for \( q \): \[ q = 15 - p \]
Now, substitute \( q \) into the second equation: \[ 3p + 2(15 - p) = 40 \] This simplifies to: \[ 3p + 30 - 2p = 40 \] Combining like terms, we get: \[ p + 30 = 40 \] Subtracting 30 from both sides results in: \[ p = 10 \]
Now that we have \( p = 10 \), we can find \( q \): \[ q = 15 - 10 = 5 \]
So, the vendor sold 10 peaches and 5 pears.
Thus, the answer is 10.