The ratio of Jacob’s pennies to Diego’s pennies is 3:4. If Diego has 24 pennies, how many pennies do they have altogether?

3:4 = 18:24

18+24 = ___