To find the total number of licorice ropes \( r \) in the bag, we need to consider how many students there are and how many licorice ropes each student receives.
Since there are 7 students and each student receives 5 licorice ropes, we can set up the equation:
\[ r = 7 \times 5 \]
Now, let's solve this equation:
\[ r = 35 \]
Thus, the total number of licorice ropes that came in the bag is \( \boxed{35} \).