Assuming you are subject to U.S. tax laws, the $5.00 loss on the one share bought for $10 would be considered a wash sale. That loss would not be allowed and would instead be added to the basis of one of the 100 shares bought within 30 days of the sale.
If this was done in a single account, the broker will probably account for this when reporting information to the IRS.
Like I was wondering what would happen. Occasionally I buy stock, and then it changes against me, and I buy more, and when selling for a net profit, some of the shares might be a loss.