Good question. I just looked up my daughter’s program. To remain in good standing in CS at the end of each semester you need to maintain an overall term of 2.3 and in the major a 2.5, no failing grades, no grade below a C- in any CS course, any math course and any course considered a technical or external specialization elective and some other things.
If you don’t meet those requirements they can kick you out of the program or give you an academic warning. Any math or CS class below C- has to be retaken.
I learned something new. 
Note: This is not Purdue, so obviously requirements are different at every school.