Let, number of tickets required so that total cost is same is x.
Cost at carnival T :
T = 0.50x + 7.00 ....1)
Cost at carnival Q :
Q = 0.25x + 12.00 ....2)
For same cost , T = Q :
0.50x + 7 = 0.25x + 12
0.25x = 5
x = 20
Therefore, for same cost at both the carnival 20 tickets should be purchased.
Hence, this is the required solution.