In India, we follow the T+2 settlement cycle. Simply put, if you buy a stock on Tuesday it gets delivered to you in your demat account by Thursday. The amusing part is that even before the delivery gets made, you are allowed to sell it. 

With BTST (Buy Today Sell Tomorrow), stock is sold even before it makes it to your demat account. 

Let’s say that you have bought 50 shares from TATA Motors on a Monday and sold them the next day. According to the settlement cycle, the shares you bought will be transferred to your demat account on Wednesday. 

On the very day, the 50 shares of the TATA Motors will be allotted based on the sale that happened on Tuesday. These shares will then be debited from your account and settled on Thursday, i.e., the T+2 day.