Implement a promotion where customers receive the Xth item for free when purchasing a specified quantity of items, such as getting the 4th item free with the purchase of 3 items.