That's wise because, until January 1, 2011, the rule for stocks was first in first out (FIFO) -- a sale of XYZ started with the oldest shares of XYZ purchased and so on up the time ladder. After that date, more flexibility was added by letting the account holder choose cost-basis method. (Long-term holding is defined as holding a stock at least a year a day from purchase. For example, anyone who bought on 03/11/2013 and sold 03/11/2014 would pay ST cap gains tax rate.) The choices of cost basis methods are:
Average cost
First in, first out: (FIFO)
Specific lot: You can pick and choose which specific shares you want to sell, to calculate your cost basis.
The usual broker default method is FIFO for stocks, options, and ETFs. However, the customer can change the overall default choice. It's prudent to double check which cost-basis default method applies to the account.