The bank will lend them money, and they will agree to pay it back, usually in equal payments over a number of years. The bank charges a fee for this, called an interest rate . You can borrow against your credit line , and repay it just as you would a regular loan. But with a line of credit, whatever portion of it you did not yet borrow is still available to be borrowed in the future. And, as you pay it back, the available portion is replenished.
Credit cards work in about the same way.
One way you access the credit card's credit line is by charging purchases at a store. For more information about the kinds of accounts you could find in a bank, look in your local library for some of the books about banking.