[Solved] Slab wise electricity bill calculation in Yii2 [duplicate]
So you simply want to multiply the amount covered by each slab (“units”) with the rate then – so I would create an array that has the slab end as key, and the rate as value – then you can simply loop over that with the extended foreach syntax, and have access to the rate … Read more