The video and steps follow.
1. Go to a merchant that sells .50 cal ammo.
2. Select all of it from their inventory.
3. Sell back one round.
4. Sell back a few more (but not all) rounds.
5. Continue selling the remaining rounds, until the merchant owes you more bottlecaps than they have in store.
6. Browse their their inventory now. Purchase all the .50 cal ammo back again. Notice that even though you're buying from them, the game tracks it as money the merchant owes you.
7. Repeat until you have plenty of bottle caps.
8. Buy everything you want. Accept the trade.
9. Enjoy until Bethesda patches. :-)
Notes: I'm playing on PS4. I've found that this works most reliably with merchants who sell .50 cal ammo, but I have got it to work on other calibers sometimes. Also, I should note that I haven't yet started a new game to verify that I can reproduce the behavior on a fresh character, but my hunch is that it'll work as I can so consistently reproduce it w/this one (and similar exploits have proved consistently available).