The most important thing is BE PERSISTENT. If your school is anything like mine, most people in your class are taking all the same classes with you. My EE classes have all 20 something of us in the same classes every semester. So a bunch of us made friends early on and do almost all our homework together. And over time, you start seeing strengths and weaknesses in each other's work. So you can all collectively help each other to understand homework or concepts, because like other people said, there will be problems and concepts you just won't pick up on quick. Don't take it personally, just stay motivated to do better. Be persistent and if there are problems you don't get, find that section in the book and do more of them. Go talk to your professors during office hours. I can't speak for all professors and TAs, but most of them will be more than willing to help you understand the material. Do not procrastinate. I can't emphasize that enough. If you have work to do on Friday, don't go out Friday and Saturday and say you'll do the work on Sunday, you'll likely not get it done. It's nothing personal. I have no idea who you are or what your study habits are like, but if you do somehow manage to get everything done, there is a good chance you won't fully understand everything. With CS or EE, concepts build pretty rapidly. So you might be ok for a bit, but then something will pop up and you'll be totally lost. So do your work early, ask for help when you need it (we all need help sometimes. Quick side note, I came back to school after a few years out and jumped right into calc 1. I needed to go find help with algebra concepts I had forgotten. Don't be afraid to ask) and most important, be persistent. Don't say "I really hope I can understand this" instead say "I am GOING to understand this" don't give yourself a choice.
But I can confidently say if it wasn't for my study group, I don't think I would be passing all my classes.