Let's denote the number of tricycles as \( T \) and the number of bicycles as \( B \).
We have two pieces of information from the problem:
-
The total number of children (riding tricycles or bicycles) is given by the equation: \[ T + B = 18 \]
-
The total number of wheels is given by the equation: \[ 3T + 2B = 43 \]
Now we can solve these equations step by step.
First, from the first equation, we can express \( B \) in terms of \( T \): \[ B = 18 - T \]
Next, we substitute this expression for \( B \) into the second equation: \[ 3T + 2(18 - T) = 43 \]
Expanding the equation: \[ 3T + 36 - 2T = 43 \]
Now simplify it: \[ T + 36 = 43 \]
Subtracting 36 from both sides gives: \[ T = 7 \]
Now that we have \( T \), we can find \( B \) by substituting \( T \) back into the equation for \( B \): \[ B = 18 - T = 18 - 7 = 11 \]
Thus, the number of tricycles is \( T = 7 \).
We verify:
- Total children: \( T + B = 7 + 11 = 18 \) (correct)
- Total wheels: \( 3T + 2B = 3(7) + 2(11) = 21 + 22 = 43 \) (correct)
Therefore, the number of tricycles is \( \boxed{7} \).