The Malayalam script evolved from:

Brahmi script
Devanagari script
Tamil script
Grantha script

The correct answer is: D) Grantha script.

The Grantha script is an ancient Indian script that was used to write Sanskrit, Tamil, and Malayalam. It is believed to have evolved from the Brahmi script, which is the ancestor of many modern Indian scripts. The Grantha script was used in Kerala from the 9th century to the 13th century, and it was the main script used to write Malayalam until the 16th century.

The Brahmi script is an ancient Indian script that was used to write Sanskrit, Prakrit, and other languages. It is believed to have originated in the 3rd century BCE, and it is the ancestor of many modern Indian scripts, including Devanagari, Bengali, and Gujarati.

The Devanagari script is an Indian writing system that is used to write Hindi, Marathi, Nepali, and other languages. It is believed to have evolved from the Brahmi script in the 7th century CE.

The Tamil script is an Indian writing system that is used to write Tamil. It is believed to have evolved from the Brahmi script in the 3rd century BCE.

The Malayalam script is an Indian writing system that is used to write Malayalam. It is believed to have evolved from the Grantha script in the 16th century.