C++ or Python?
Up until this point, the commands for ROOT/C++ and Python/ROOT were nearly identical.1 I presented them in the context of using cling, ROOT’s C++ environment.
From this point forward, using ROOT/C++ is different from using Python with ROOT extensions (“pyroot”). You have to decide: in which language do you want to use ROOT? My initial advice is to ask your supervisor. Their response, in ascending order of likelihood, will be:
A clear decision (C++ or Python).
“I don’t know. Which do you feel like learning?”
“I have no idea what you’re talking about.”
If it’s up to you, this may help you decide:2
In favor of Python:
Learning Python is easier and faster than learning C++.
Python can be more appropriate for “quick-and-dirty” analysis efforts, if that’s the kind of work you’ll be doing this summer.
In favor of C++:
If you’re going to be working with your experiment’s analysis framework, it will almost certainly involve working in C++.
See here for the differences when using Python versus ROOT/C++.
Here are the areas in which neither has a clear advantage:
Both C++ and Python are used worldwide, so knowing either one is useful.
Python’s interactive development is usually cited as an advantage over C++, but ROOT offers the interactive C++ interpreter, cling.
Both languages have substantive numerical computing libraries (e.g., SciPy in Python, GSL in C++).
There are various tricks for making Python run faster; e.g., the %pypy cell magic, the Cython extension, list comprehensions, clever use of numpy. You’ll learn about them if you choose to become a Python expert.