How do they calculate this payment?:

What you pay will vary depending on your balance, the interest rate and the way your finance charge is calculated. Here's an example that shows
how much difference the interest rate can make in what you actually end
up paying:

High-rate card - Suppose you charge $1,000 on a 23.99-percent credit card. After that, you make no further charges and pay only the minimum each month. The payment will start at $51 and slowly work its way down to $10. You'll make 77 payments over the next six years and five months. By then, you will have paid $573.59 in interest for your credit privilege.

Low-rate card - If you charge that same $1,000 on a 9.9-percent fixed-rate card, the minimum monthly payment will start at $50.41 and go down to $10. You'll make 17 fewer payments, finishing in six years and paying $176 in interest. This saves you almost $400!

How do they get $51 from 5%, 23.99%, and $1000. Likewise for the second one.

What you pay will vary depending on your balance, the interest rate and the way your finance charge is calculated. Here's an example that shows

High-rate card - Suppose you charge $1,000 on a 23.99-percent credit card. After that, you make no further charges and pay only the minimum each month. The payment will start at $51 and slowly work its way down to $10. You'll make 77 payments over the next six years and five months. By then, you will have paid $573.59 in interest for your credit privilege.

Low-rate card - If you charge that same $1,000 on a 9.9-percent fixed-rate card, the minimum monthly payment will start at $50.41 and go down to $10. You'll make 17 fewer payments, finishing in six years and paying $176 in interest. This saves you almost $400!

How do they get $51 from 5%, 23.99%, and $1000. Likewise for the second one.