Why a plastic cup when put in microwave melt but gas it melt?

Plastic cups are made from polymers, which are long chains of carbon atoms. When polymers are heated, the chains begin to vibrate and eventually break apart, causing the plastic to melt. However, when a plastic cup is put in a microwave, the microwaves cause the water molecules inside the cup to vibrate and generate heat. This heat can cause the plastic to melt, but it can also cause the water to boil and turn into steam. The steam can then escape through the small holes in the cup, preventing it from melting.

In contrast, a glass cup does not contain any polymers. Instead, it is made from silicon dioxide, which is a mineral that does not melt easily. This is why a glass cup can be safely used in a microwave without melting.