Can anyone help me.

Of course I only want to know the principal amounts of a given loan.
But I want to incorporate a prepayment that would affect the remaining loan
amount.

For example:
The loan amount is 375,000
the annual intrest rate is 18.00%
Loan period in years is 5

I have a spreadsheet that has 60 columns with a constant loan amount
and 60 rows with the principal amount in each row.

375,000 457,000 457,000 398,000 so on ----> until 60

row 1 3,897.54
row 2 3,956.00
row 3 4,015.34
row 4 4,075.57
row 5 4,136.70
row 6 4,198.75
row 7 4,261.73
row 8 4,325.66
row 9 4,390.54

If I put a prepayment in row 6 how can I calculate the remaining principal
amounts.

Thanks