Final answer:
Massive stars with a mass more than 20 times that of the Sun can become black holes through a supernova explosion and subsequent core collapse.
Step-by-step explanation:
Massive stars that have a mass more than 20 times that of the Sun will often end their lives as black holes. These stars go through a supernova explosion at the end of their lives, whereby the outer layers are expelled into space, and the core collapses under gravity. If the core is massive enough, it will continue to collapse until it forms a singularity, creating a black hole.
Learn more about The process of stellar evolution leading to the formation of black holes