是in university还是in the university?

都是对的。要看语境。来

in university表示在学校里,在学校期间;(泛指)

in the university表示具体的大学,指定了固定的对象。(特指)