What is the purpose of THC for a Cannabis plant?
Apparently it is used by Cannabis sativa as a type of sunscreen as it absorbs UV light
https://www.reddit.com/r/trees/comments/2v79dv/science_sunday_13_wait_why_does_cannabis_have_thc/

https://en.wikipedia.org/wiki/Tetrahydrocannabinol