So at least in that sense, I think you can get something similar out of the two.
Maybe a better analogy is musical instruments. I've heard knowing how to play multiple instruments offers significant cognitive benefits.
As far as I know, people don't think in Python or C. I would say that a programming language is like math. You can use it as a plugin in your language, but you still need the main program which is your language.
Furthermore, programming languages are written in English. A real language cannot be written in another language.
I'm not a linguist nor a programmer, but I'm trilingual, and I have scripted at a basic level. And honestly, although I see the resemblance, I don't think that programming languages and real languages work the same way.
Are you saying people don't think in math? They definitely do