I am totally with @roundsquare: B’s behavior was outrageous, no way to treat a friend. If I were person A, I would pay person B back, with carefully computed interest, if it was the last thing I did. And with person B, it probably would be.
Person D can remember letting person C off the hook for a hundred dollars some years ago, when the issue was a joint wedding present and person C was a little short. Person D’s memory is a little too good about these things, but the fact is that she learned a long time ago to treat any loan as a gift (which is to say, you don’t lend anything you can’t afford to write off). Once about ten years ago, when person C was far from short of cash and was in fact kind of ostentatiously throwing it around, person D said to person C, “We gave Person W that nice crystal ware together, do you remember?” and that’s the closest she ever came to reminding person C, who was oblivious. It’s simply gone, and that’s that.
(Person D feels better about letting it go than she would about bringing it up after all this time. It’s her choice. But she never “goes in” with C on presents any more.)
I think the lesson for person A in this situation is to remember to say “You know what? I can’t be thinking of eating out right now. I have to watch my nickels pretty closely.” And decline any offer of a loan.
Person D is speaking from a place of remembering living on lettuce sandwiches and homemade bread for a week because the lettuce was free leftovers from someone’s party and the bread ingredients cost 52 cents; going to the store with seven cents found in a pocket and buying one potato for supper; having a major family discussion over whether or not to spring for a 39-cent roll of Scotch tape; looking upon a bag of potato chips as an unattainable luxury. Person D understands.