He paid around $20 billion cash (by selling Tesla stock) and loaned another 6.25 billion personally (loan secured by more Tesla stock). The rest was funded by various bank loans that are now owed by Twitter itself.
One of the neat tricks you can do when you’re wealthy is loan billions of dollars to buy a company, then you put those loans in the name of the company you just bought, so you don’t have any personal risk. The reason he still needed to pony up $26 billion in cash is because banks thought it was too risky to loan the full amount. They might now regret loaning even this much, Twitter has a substantial debt burden and I understand ad revenues aren’t doing great.
Obviously, since the company is private now we don’t get as much insight into financials.