We use used to + infinitive if we need to talk about an event that took place in the past and was true.

 

I used to be a great student in class.