The reason that so many people make a good living preparing taxes is that most people 2 or 3 times your age don't know nost of the details.
If you win enough, you'll get a form W-2G along with the money. "Enough" means $600 or more. Your winnings will get listed on your 1040. You can only deduct losses up to the amount you won, and only if you itemize your deductions. At 19, with modest winings I'd guess you have no reason to itemize. In your example, you've got $15 in taxable winnings, and you could therefore deduct $15 of the $31 you spent. Yes, there's a point to listing the losses. If you didn't, 100% of your winnings would be taxable, instead of just your profits. If you were to win $1000 and you had spent $1000, you'd break even, unless you declared the winninsg without deducting the losses.
One of the things that many people are confused about (including people here, and you may well see a post claiming I'm wrong) is the taxes on winnings. All winnings* are taxable income. You'll only get the W-2G form, and the IRS will only be notified if you win $600 or more, but even a $15 proze is taxable. The IS not knowing you had income may mean they won't notice if you don't declare it, but it doesn't mean they can't hit you with penalties and interest if they find out. As a practical matter I doubt they'd care about the $15 even if you got audited and let it slip. OTOH, once in a while somebody wins $5000 by playing the same pick 3 number on 10 different tickets. Having 10 separate $500 winners means there are no forms, but if the IRS were to find out you had won that much and didn't declare it, you could potentially be very unhappy with the results.
*I'm only talking about federal taxes. Several states exempt winnings in their own lotteries. For example, if you won PB with a PA ticket, PA wouldn't tax the winnings. Your state of residence, if it wasn't PA, would, assuming they have a state income tax.