UCD(CS) vs UCSD(Physics)

If CS is want you to study and you got a direct admit into UCD, I would favor UCD over UCSD. Changing into CS is extremely difficult and has been by lottery the last few years.

https://cse.ucsd.edu/undergraduate/cse-capped-major-status
https://ucsd.edu/catalog/curric/CSE-ug.html