Last active
March 9, 2023 23:40
-
-
Save savarin/c59fcc3669a36751598e4c4555abe33f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Question: | |
Is there a reason you switched from "interpretable" when there were 4 groups to | |
mean "there is only one way to do things and thus interpretable to humans", but | |
when there were 8 groups you mean "interpretable by the machine"? | |
Answer: | |
I apologize for any confusion caused. The term "interpretable" can be used in | |
different contexts and with different meanings. In the first categorization with | |
four groups, I used "interpretable" to refer to languages that are human | |
-readable and allow for clear understanding of the code's behavior. In the | |
second categorization with eight groups, I used "interpretable" to refer to | |
languages that can be executed by a virtual machine or an interpreter rather | |
than being compiled into machine code. The distinction between the two usages of | |
"interpretable" is important and may have led to the confusion. | |
To clarify, in the second categorization, the languages in the "Interpretable | |
and expressive" and "Interpretable and static" categories are considered | |
interpretable because they can be executed by an interpreter or a virtual | |
machine, allowing for easier portability of the code across different platforms. | |
The languages in the "Highly interpretable" category are low-level languages | |
that can be directly executed by a computer without the need for an interpreter | |
or a virtual machine, but may be more difficult for humans to read and | |
understand due to their lower-level syntax. | |
Question: | |
Isn't Perl known for "there is more than one way to do it"? | |
Answer: | |
Yes, Perl is often associated with the slogan "there's more than one way to do | |
it" (TMTOWTDI), which reflects its emphasis on expressiveness. Perl offers a | |
wide range of features and syntactical constructs that allow programmers to | |
solve problems in multiple ways. This flexibility and power are what make Perl a | |
highly expressive language. The TMTOWTDI philosophy is often cited as one of the | |
strengths of Perl, as it allows programmers to choose the most suitable approach | |
to a problem, and encourages experimentation and creativity in programming. | |
Therefore, Perl should be included in the "Emphasis on expressiveness" category | |
along with other languages like Prolog, Lua, Ruby, JavaScript, and PHP. | |
Question: | |
Isn't Python known for "there is only one way to do it"? | |
Answer: | |
Python is often associated with the "There should be one-- and preferably only | |
one --obvious way to do it" (TOOWTDI) philosophy, which suggests that there | |
should be a preferred way to solve a particular problem that is clear, concise, | |
and consistent. This philosophy aims to make the code more readable, | |
maintainable, and reliable. | |
However, this doesn't mean that Python has only one way to do things. In fact, | |
Python is a highly expressive language that provides a wide range of tools and | |
features that allow programmers to solve problems in multiple ways. Python's | |
standard library, for instance, includes a diverse set of modules that provide | |
different ways to accomplish common tasks. Moreover, Python's flexibility and | |
dynamic nature enable programmers to express their ideas in various ways. | |
Therefore, while Python may emphasize a preferred way of doing things, it is | |
still a highly expressive language that provides multiple options to solve | |
problems. Hence, Python should be included in the "Expressive and dynamic" | |
category along with other languages like JavaScript and Lua. | |
Question: | |
In this case it means Python is more opinionated on how we should do something? | |
Answer: | |
Yes, that's a good way to put it. Python, with its "There should be one-- and | |
preferably only one --obvious way to do it" philosophy, is more opinionated on | |
how things should be done than some other languages. Python's design favors | |
simplicity, readability, and consistency, and encourages programmers to write | |
code that is easy to understand and maintain. | |
While Python provides multiple ways to solve a problem, it emphasizes a | |
preferred way of doing things, which can be seen as more opinionated than | |
languages that do not have a strong emphasis on a particular approach. This | |
opinionated nature can be seen as a strength or weakness, depending on the | |
situation, and can influence the programming style and decision-making process | |
of Python programmers. | |
Question: | |
For Rust, which is both expressive and interpretable, there are many ways to do | |
something but at the same time, there should be only one obvious way to do it? | |
Answer: | |
Rust is a programming language that aims to provide a balance between | |
expressiveness and performance, while also prioritizing safety and correctness. | |
Rust's syntax and features are designed to be expressive and flexible, allowing | |
programmers to solve problems in various ways. At the same time, Rust also | |
emphasizes a "one obvious way" philosophy, where there is a preferred way to | |
solve a particular problem that is clear, concise, and consistent. This | |
philosophy is reflected in Rust's documentation and community norms, which | |
encourage best practices and discourage overly clever or complex solutions. | |
The emphasis on a preferred way of doing things in Rust is not as strong as in | |
some other languages like Python, but it is still an important aspect of the | |
language. The "one obvious way" philosophy in Rust is not meant to restrict | |
creativity or experimentation but rather to promote code that is easy to | |
understand and maintain. Therefore, Rust can be included in the "Both | |
expressiveness and interpretability" category, along with other languages like | |
Haskell, OCaml, Erlang, Scala, F#, Elixir, and Swift. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment