One of the easiest Approach in Basic way with explanation .Here you can understand it very easily,
Intuition\n Describe your first thoughts on how to solve this problem. \n\n# Approach\n Describe your approach to solving the problem. \n\n# Complexity\n- Time 
# Intuition\n<!-- Describe your first thoughts on how to solve this problem. -->\n\n# Approach\n<!-- Describe your approach to solving the problem. -->\n\n# Complexity\n- Time complexity:\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity:\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\n/**\n * @param {number[]} bills\n * @return {boolean}\n */\nvar lemonadeChange = function(bills) {\n\n//create a object to calculate your currrent balance of money\n    let obj ={\n        five:0,\n        ten:0,\n       \n    }\n//itrate through the  amount and do curresponding changes in the obj (balance) and return false if you get out of money to give balance to the customer\n\n\n    for(let i = 0 ; i < bills.length ;i++){\n        console.log(obj)\n        if(bills[i] == 5){\n         obj.five +=5   \n        }else if(bills[i] == 20){\n            if(obj.ten >=10 && obj.five >=5){\n                obj.ten -=10\n                obj.five -=5\n            }else if(obj.five >=15){\n                obj.five -=15\n            }else{\n                return false\n            }\n        }else{\n            console.log(i,bills[i])\n            if(obj.five >=5){\n                obj.ten +=10\n                obj.five -=5\n            }else{\n                return false\n            }\n        }\n    }\n\n    //return true means you have successfully gave the balance to the customer \n        return true\n\n\n};\n```
['JavaScript']