In order to apply for CS in college, how many years of Physics is recommended in HS?

The top CS schools care more about your math background than your CS background when admitting you into their CS program. For e.g., CMU really likes you have to have done discrete math or number theory vs AP Stat (considered light) if they are evaluating you for an SCS slot. AP Calc BC is generally taken for granted for most good CS program admissions.