r/AskProgramming • • 4d ago

Career/Edu C++ vs python

I'm a first year cs student and I'm wondering which is better for getting a job. I know it's more about your skills and not only the programming language but they do have different niches that they excel in.

The reason I'm asking is that I already know Python and have done extensive work in it. But I recently discovered C++ and truth be told I really like it and prefer it over Python. C++ just has so much more control and logic that you can manipulate in it. It feels more concrete for some reason.

Either way, I know learning Python is essential cuz it's the fastest way to get things done. But at the same time it's also the most popular language, so I'm wondering will learning C++ be worthwhile?

5 Upvotes

22 comments sorted by

2

u/EngineersUniverse 4d ago

if you already know Python and actually enjoy C++, I’d say go for it. Cpp teaches you stuff about memory, performance and how computers actually work that Python tends to hide from you. Cpp is big in embedded systems, robotics, game engines, high-performance computing and finance. Python dominates in AI, automation and data science. honestly, you’re in your first year. Don’t worry too much about which language gets you hired. Get really good at programming, build some cool projects and learn how things work under the hood. For a practical path, I’d start with modern C++ basics, pointers, references, memory management and STL. Then move into data structures and algorithms, and actually implement them yourself instead of just grinding LeetCode. After that build 2-3 projects, maybe a CLI tool, simple HTTP server or a multithreaded application. Learn Git, CMake and basic debugging with GDB along the way. check out learncpp.com, it’s free and very solid. knowing both is a great combo. if you genuinely enjoy C++, that’s even more reason to stick with it. don’t get stuck watching tutorials forever, build stuff and break things.

2

u/ElephantOdd5341 4d ago

I already know git and I've used Python for multithreading and qiskit.

Another reason I want to know C++ is coz even for AI the background work is mostly done by C++ and it works in most of the things at the bottom. Also I kind of detest frontend

1

u/max123246 4d ago

Actually in the AI world I would say C++ isn't the majority anymore. The new hotness is GPU dsls such as triton, cutedsl, cutile, and mojo. Cutedsl and cutile for example is in python, actually, though it won't look like normal python at all. And mojo is python -like. Of course pytorch is a python framework for ML research, not writing gpu kernels

If you want to get into GPU programming, cuda c++ is a good place to start to learn SIMT style kernels for HPC type of workloads but you'll want to get into tensor core programming using tile based programming languages for any ai workloads

7

u/Former_Produce1721 4d ago

I recommend learning at least 1 high level language (Python) and 1 low level language (C, C++, Rust)

They are different tools for different uses

1

u/prodjsaig 4d ago

I would experiment but there is so much that anything advanced like build systems you would get shown on the job. Play around install Linux and have fun. You learn best by doing and not getting overwhelmed which is why nothing is a waste of time.

1

u/ElephantOdd5341 4d ago edited 4d ago

That's a great answer mate, thanks

1

u/Available_Safe1818 4d ago

Look at some job ads and you'll see.

1

u/gosh 4d ago

python is more or less dead, instead most use AI to generate python code. The reason is that python is very declarative (declarative = say what you want to do).

C++ is the most imperative language out there that is a multiparadigm language. (Imperative = say how to do it)

Imperative are what programming is about.

1

u/DDDDarky 3d ago

I know it's more about your skills

As you have said, programming language is not that important, but you should have certain skillset which will depend on your field of expertise, certain languages are used in different areas, for example if you wanted to specialize on game dev, you should definitely focus on C++, if you want to go into data science, python may be more useful.

Python is essential cuz it's the fastest way to get things done

It's not essential but it can come in handy for example if you want to quickly prototype somehting.

it's also the most popular language

It's not, but consider that "more people use it" is really meaningless, job market obeys laws of supply and demand, many people use it means there is large supply, that is true for python, I would doubt there is demand to match it. On the other hand well educated C++ pros are more rare and there are many use cases, which may result in better job opportunities. All that can of course differ from place to place, so you should do your own research in the area where you live to get a better picture.

1

u/eyes-are-fading-blue 3d ago

“Language isn’t important” is one of the worst advice you can give to a student. Tool mastery is extremely important.

1

u/DDDDarky 2d ago edited 2d ago

Is not "that" important. If you know the concepts one can pick up new languages quite easily.

1

u/eyes-are-fading-blue 2d ago

It is far less important than it should be. Unfortunately.

1

u/good_name_0 3d ago

It's important to branch out, definitely learn it

1

u/Difficult-Tutor7855 4h ago edited 4h ago

First of all, as a computer science student, your goal is to understand how computers work of which you'll be needing at least one programming language for experiments. And you have chosen the right language, C++. You're meant to discover concepts, create your own principles, research and make existing theories better. Your job is to make life of programmers better by creating better algorithms, more efficient tools.

Here's an example. GraphQL is an API query language. A concept designed to make fetching data efficient. It is designed as a solution to the inadequacies of REST API. Mind you REST API was a concept designed as a solution to a problem that existed as well. These are top level problems where you define how programmers interact with computers. This is the level you study computer science to operate in. You define the principles on computers are meant to operate on. You define computing itself.

Programmers are not really far fetched from users of any other application because to use any application you'll need to understand how the application works. So it is with any programming language.

So you don't study computer science to become a programmer, you'll need to see beyond programming

1

u/Objective-Light-7123 4d ago

Rust and Python.

Start with Python then rust.

Python is great for prototyping.
Rust is great to make sure your bugs won’t be runtime bug. AI models drive it better as the compiler is strict and the error messages very clear.

0

u/Notsoboringi 4d ago

Finding job in c++ is harder and there aren't that many entry roles , but u can find entry level roles in python , if u have already done django , fastapi, ml , dl then idk.

2

u/max123246 4d ago

Tons of entry roles for C++. You just have to know where to look and build experience towards it. Gpus with Cuda C++, compilers with llvm, quant, embedded, robotics etc

2

u/Notsoboringi 4d ago

There are but they don't hire freshers , it's best to get little experience then look for c++ roles .

1

u/max123246 4d ago

They hired me out of undergrad 🤷

1

u/Notsoboringi 4d ago

Nc ☺️

0

u/powderviolence 4d ago

They can both do everything the other can. C++ requires more lines for the same task, but with the benefit you mentioned of greater control and the ratio of lines to actions being close to 1. Python is popular in industry because it does MORE with less, and is lexically similar to English such that more people can write it than can write C++ with the same level of background ability. It really becomes a question of what you want out of the whole endeavor.

-1

u/CorpT 4d ago

Just take your classes and learn whatever.