Karlie here from the Shopify Support Team! You have a couple of options when it comes to setting up a product limit like the one you're looking for. You could either set up some bundles manually within your Shopify Admin, you could use an app or even create a discount code.
To create a product bundle within your Shopify Admin, you would simply just create a product and the title could be, "4 for $5" - the description could say something along the lines of "Buy 4 of this product and pay a discounted amount of 5$" and you would just adjust your product images to have 4 of that product in the image as well as adjust the inventory.
You could also try creating a discount code from within your Shopify Admin. If you were to create a discount code by the fixed amount then you could use this guide and make sure your 'Minimum Requirements' are set to '4' and then you can set your discount value to whatever you'd like to offer the customer.
I hope this has answered your question. If not, or if you have any further questions please let me know. I will be happy to help!
Karlie | Social Care @ Shopify - Was my reply helpful? Click Like to let me know! - Was your question answered? Mark it as an Accepted Solution - To learn more visit the Shopify Help Center or the Shopify Blog