I am computer engineering student(Our curriculum is 80% similar to electronics engineering in our country so you can call me electronics engineering student as well tbh). But this thing is relevant to electronics engineering as well so I am asking it here. I still don't know how to program. I of course can code very tiny tiny programs like prime number etc etc...But I am nowhere near the level of building big programs like using frameworks to make stuffs and so on.
I dont know at which year you are in the university. It can be very similar in the first two years, and it is not necessarily a bad thing. It was ~20y ago, but I studied both of the programs (electronics & computer), so I know similarities and differences pretty well (of course biased, depends on country and university). Also, you say your program is named computer engineering, usually computer engineering is more close to electronics than computer science programs.
If after first two/two-and-a-half years they are still too similar (which is weird, either electronics is too computer-ish, or computer is too electronic-ish), check the curriculum of the computer degree program of a few well known universities. There are very basic, and must have classes that should be common, so if you miss any of these in your university, try to study on your own, so many very good resources on internet now.
Of course these are relative terms, there are exceptions and no rules, but you will probably be nowhere near writing a "big" software until you finish the school and work for a few years. Dont worry if this is the case, it is normal.
I learnt c, c++ and python and bit of javascript. But all of them were useless. I learnt programming languages and not programming.
It is pretty difficult to "know" computer languages to an extent you can say you are comfortable with them to express what you want well. I learned BASIC and Pascal when I was a kid, used them many years for fun. I learned and used c after high school often, but I can never say I know it well. I used c++ somehow at an advanced level for a time period during commercial game development, I remember almost none now. I used python maybe for 15 years, but never made a big software, so I cant say I know it. I loved LISP variants (Clojure), I am nowhere near knowing it. I used Java heavily and commercially, even with that it was hard to say I know it well. The comfort you have with the languages all depend on exercise. As you do with a foreign language or a musical instrument, the more and heavily you use one, you become more and more comfortable using it. When you know a language better, you also get better at expressing yourself with that language. When you know the computer science basics, it is not difficult to express a problem with them if you are comfortable with the language. Neither alone is enough to get better at programming.
It is early for you to think about this but also languages have a certain history and have a different level or sense of expression. C, Java and Python are all very different, LISP is another world. You would not like programming in Java if you write a device driver, you would not like C if you do something else etc. Unfortunately it takes time to have a sense of this, and cannot be learned from the books alone.
I know assebly language coding in 8085 and 8086 microprocessor. I didn't learn 8051 quite well though.
Programming itself is a large topic like computer science and electronics eng. It is easy to say you have to focus on something, but it is hard to do (what to focus on?). But at the end you will not be good at many things, so accept it as early as possible. Once, I knew PC architecture pretty well, then I knew Windows pretty well, then I knew mobile world well, then backend/server etc., but this covers like 25-30 years. I only coded a very simple device driver once for fun, so it is normal to not know things. After some time, the important thing is not to know how to do it, but to know how to learn how to do it.
Because you mentioned the CPUs, one of the classes you have to learn well is computer architecture. This is normally not taught in electronics. The other classes, most of them if not all, normally not taught in electronics: algorithm analysis, operating systems, abstract math/formal languages/automata theory, computer networks. Depending on what you do, you might not use what you learned in some of these classes at all, but they will give you something valuable which can be applied anytime to any problem.
There are also artificial intelligence and machine learning classes, but they might be advanced and given only at post-graduate level.
I think this question is relevant to electronics engineering students in my country(Nepal) as most electronics engineering students pursue career in coding like web development. Any way, coding is essential part of electronics engineering, we all know about that.
Probably in many countries if not all countries, there are more computer/IT/software related jobs than electronics, so I think it is pretty normal particularly if the country does not have a strong electronics industry (nothing against Nepal, only a few countries have strong electronics industry).
I am currently learning python. I learnt syntax of python. And I am currently solving codewars problems. I read other person's solutions as well and try to understand at least 5 different solutions to a problem. My logic has improved a bit in programming but I consciously want to know how to improve my logic in programming? What else can I do to improve my logic in programming? Any guidance will be extremely valuable.
Other than learning the basics from the books, lectures etc. I think two best things to do; 1) read others code (so many very good open source projects), 2) write code (find a project, fix something in another project or do internship/work part-time in a company). Python is a good choice by the way. If you have hard time to find a project, just copy the idea and re-implement a simple version of an existing software (e.g. write a web server).