Why does our hair turn white before we get old?
Human hair color depends mostly on two pigments: eumelanin and pheomelanin. Eumelanin has brown and black variants, whereas pheomelanin is reddish/orange. Cells at the base of hair follicles produce those pigments and white hair is simply lack of those pigments. There may be many reasons why your hair is turning white at a young age:


melanocyte stem cell damage at the base of the follicles
vitamin B12 deficiency
problems with the thyroid
deficiency of catalase as in vitiligo (hydrogen peroxide would then accumulate and impair pigment production)


But most of the cases are purely genetic and you should not be worried if you are certain your B12 levels and thyroid are OK. Here's an article on that topic: https://www.ncbi.nlm.nih.gov/pubmed/23974581

There's also quite a bit of information on white hair on Wikipedia: https://en.wikipedia.org/wiki/Human_hair_color#cite_note-18
(sections Grey and white hair and Aging and achromotrichia)

Cheers!