updated while loop in SNPgrade to load new values in studTemp after incrementing index