Kevin and Randy Muise have a jar containing 52 coins, all of which are either quarters or nickels. The total value of the coins in the jar is $6.20. How many of each type of coin do they have?

Let q be the number of quarters, and n be the number of nickels. We have: