Which programming language is best?

AI Thread Summary
For high school students interested in majoring in Physics, learning a programming language is highly recommended. Python is frequently suggested due to its user-friendly nature and suitability for calculations and simulations, making it an excellent starting point for beginners. C++ is also mentioned, particularly for its relevance in university courses, but it is considered more complex and lower-level, dealing directly with system memory. The discussion emphasizes that there is no single "best" programming language; the choice should be based on individual needs and goals. Other languages like Java, FORTRAN, MATLAB, and R are noted for their specific applications in scientific fields. Ultimately, the focus should be on developing a programming mindset and understanding fundamental concepts, as these skills are transferable across various programming languages. For those with an interest in biology, Python is also recommended, especially for applications in bioinformatics.
Eroki
Messages
4
Reaction score
0
Hello, I am currently a Junior in high school and am interested in majoring in Physics when I go off to college. I have looked online and saw that many people have suggested learning a programming language and was wondering which language would be a good one for me to learn saying I would be trying to teach myself and have only small experience working with code when my science class did stuff using the Arduino prototyping board. Also any other advice you would give a high school student looking into going into Physics would be greatly appreciated.
 
Physics news on Phys.org
Define best!

Different programming languages are better in different ways. What are you looking to do? Calculations? File parsing? Web development?
 
Well I really do not know much about what i exactly would need to know but I would assume probably code for thing that do calculations and simulations. Though any places for me just to get familiar with code would be helpful.
 
There are few threads dealing with this issue of what programming language you should learn. I would choose Python and C++. I haven't had experience with Python but I hear its easier to learn than C++ and deals more with numbers and simulations(?). C++ is the programming language that students typically start off with in my University.

Refer to this thread:

https://www.physicsforums.com/showthread.php?t=504442
 
Ok Thank you I will go check that out
 
C++ is very low level in the sense that it deals directly with system memory etc. and IMO is much harder to learn than python. With programming its probably easier to learn the harder programming languages first like c++ because the fundamentals become so much easier and python will seem like a piece of cake to you. Does your high school offer an AP Java class or something along those lines? I know its not C++ but the Ap Java class in my high school is helping me a lot right now in terms of the fundamentals.
 
No I am not able to take any programming classes unfortunately. I go to a small school with almost no advance classes. The closest thing we really have to advance classes next year is we are able to offer calculus which normally we are not able to give because not enough people willing to take it
 
There is no such thing as best programming language. You cans simply google "best programming language". You choose the language based on your needs. Python is popular for rapid development, over Java and C++.
There are many languages out there. You certainly don't want to write a website using C / C++. It can be done, but takes a lot of efforts. FORTAN is still widely used in the scientific community. MATLAB - it's usually used for large numerical data sets. Mathematica, from what I heard is good for symbolic computation.

Nonetheless, the popular one tends to be "C, C++, C#, Java, Python, Perl, Assembly"... I list assembly because somehow a good programmer should know a little bit of assembly
 
Last edited:
  • #10
Hi,

I have a question similar to OP's that some of you might have an answer to. I'm going to university next year as a biology major and I want to learn a program language as I think it may prove beneficial for something later on (grad school, career, etc). Any suggestions on what I should learn?

Thanks.
 
  • #11
What kind of biology do you want to do? I think my ecology friends are big on R, but most of the biochem/biophysics people I know (which is admittedly far from representative) use Python.

In the long run, it doesn't really matter which language you learn first. The important part is getting used to the programming mindset (i.e. "thinking like a computer"), and getting a taste for the basic concepts that are found in nearly all programming languages (for loops, while loops, arrays, if/else statements, etc.). I'd personally recommend Python, but it's hard to go wrong with any of the commonly-used languages.
 
  • #12
If you want to be good at programming learn each type of language. C++, Java, Lisp, Assembly, and Prolog, would be a good set of skills to know, seeing as they are all very different. If you intend to use embedded hardware such as Arduino, you should probably learn C/C++ or assembly. Python or MATLAB is probably better suited if you intend to do science, but it depends on what level.

chez_butt23:
For learning a language suited towards biology Python would be a good choice, I know lots of people studying bioinformatics use it. But if you can learn several it would be better then learning one, I'd also learn Java/C++, and possibly something like Perl. As these tend to be used in computational biology. Learning a framework such as BioPython, BioJava, BioPerl, or something similar would also be beneficial.
 
Last edited:
  • #13
"Python or MATLAB is probably better suited if you intend to do science, but it depends on what level."

Nonsense in regards to python - it is fantastic for rapid development for even desktop apps on Win, Mac and *nix as well as web dev.

Learn Python and C or C++ and take it from there, that will give you a rapid dev scripting language as well as the lower level language, match made in heaven.
 
Back
Top