a. 坏了【huàile】is used for an object is broken or not worked properly such as machine, home appliances, electronic item, furniture, glasses, etc.
Example 1:
That table is broken.
那【nà=that】张【zhāng =a measure word for tables】桌子【zhuōzi=table】坏了【huàile=broken】。
那 张 桌子 坏了。
Example 2:
Older brother's mobile phone is broken.
Older brother's mobile phone is stop working.
哥哥【gēgē=older brother】的【de】手机【shǒujī=mobile phone】坏了【huàile=broken, stop working】。
哥哥 的 手机 坏了。
Example 3:
His glasses is broken.
他的【tāde=his】眼镜【yǎnjìng=glasses】坏了【huàile=broken】。
他的 眼镜 坏了。
b.坏了【huàile】is also used for an object that is expired such as food, beverage.
Example 1:
The bread that I just bought is already expired.
我【wǒ=I】刚【gāng=just】买【mǎi=buy】得【de】面包【miànbāo=bread】已经【yǐjīng=already】坏了【huàile= expired, broken】。
我 刚 买 得 面包 已经 坏了。
Example 2:
Soya-bean milk is expired.
豆浆【dòujiāng= soya-bean milk】坏了【huàile=expired, broken】。
豆浆 坏了。
Others things that use Chinese words meanings broken坏了【huàile】, such as: 蛋【dàn=egg】,牛肉【niúròu=beef】, 蛋糕【dàngāo=cake】, 电视【diànshì=TV】, 机器【jīqì=machine】, 计算机【jìsuànjī=calculator】, 照相机【zhàoxiàngjī= camera】.
c. 坏了【huàile】can also be used as metaphor.
Example:
He is crazy.
Literally means," His brain is busted/broken".
他的【tāde=his】脑子【nǎozi=brain】坏了【huàile】!
他的 脑子 坏了!
Compare that with example 2:
The doctor says, "His brain is damaged".
医生【yīshēng=doctor】说【shuō=say】,“他的【tāde=his】脑子【nǎozi=brain】坏了【huàile】”。
医生 说,“他的 脑子 坏了”。
Here the patient's brain is really damaged.