I often hear the term accrued interest when dealing with loans and investments. From my understanding, it refers to the interest that has been earned or incurred but not yet paid. Can someone explain with a simple example how accrued interest is calculated and recorded in financial statements?