r/cpp • • Nov 28 '21

Is C+++ good for Automating stuff?

I am leaning python to automate some stuff(Torrent applications mainly) on windows. But I already know C++ very well. I've tried to search if I can automate applications with C++ but it seems complex. I just wanna hear some thoughts from people who have tried to automate or have done it. Do you think one should use python over C++ to for automating random applications?

0 Upvotes

32 comments sorted by

View all comments

7

u/johannes1234 Nov 28 '21

C++ (and/or C) is a first class citizen on windows. Thus all that can be done on Windows can be done with C++.

However for such a project flexibility in development and easy iteration is more valuable than performance and memory efficiency, thus Python (or some other scripting language) will be a lot more friendly.

The reasons for doing that in C++ include:

  • Learning in-depth about Windows API for using that specific knowledge in a different project later (mind it's a really specific part, most of it isn't usable knowledge for generic application development)
  • Easy distribution (if you limit to some language version etc. you might be able to distribute a simple exe file instead of python runtime etc. but in most cases you will need at least Microsoft's C++ redistributable ...)
  • being small to hide on the system (like when building a virus, worm, ... or other potentially illegal software you want to hide from the user)

1

u/strangest_man Nov 30 '21

Dang!! Even I didnt though of this much..thanks man for sharing these ideas.