Some fun but mind-blowing fact for the computational knowledge I've learnt through the first week of this course:
Nearly all programming languages is capable of solve any computational problem.
The keyword here is Turing Completeness. C, C++, C#, (Visual) Basic, Pascal, Python, Java, Ruby, Objective C, Perl, Swift, and so on are all Turing complete programming language that has been used to create masses of software and programs.
To achieve Turing completeness, a particular must be able to complete this 6 primitive:
- Right: Move the Machine’s head to the right of the current square
- Left: Move the Machine’s head to the left of the current square
- Print: Print a symbol on the current square
- Scan: Identify any symbols on the current square
- Erase: Erase any symbols presented on the current square
- Nothing/halt: Do nothing
Maybe this little video would help you better in understanding the theory.
In short, any languages can achieve this six primitives can solve any computaional problems(regardless of effectiveness) which also reveal the my biggest, constant question in the mind:
Anything that can be done in a programming language can be done as well in other languages.
Provided they are Turing complete, of course.
The answer is probably yes, most of the time. In fact, a better question is, Is X language more effective than Y language in programming Z function?
Image taken from http://www.felienne.com/archives/2974
Posted from my blog with SteemPress : https://fr3eze.vornix.blog/the-fact-of-all-programming-languages/