How can I prevent hair loss?

I’m a 22 year old male who is experiencing hairloss on the corners of my forehead, what can I do about it? Is there some cure for it?