Which programming language has more expressive power: LISP or C++?
LISP is more expressive than C++. Most people wouldn't agree, because they are not well-versed in functional programming or symbolic logic, and have a limited understanding of how computer science works.
First, I should clarify what I mean by expressive power. Expressive power refers to the ability of a computer program or programming language to represent concepts and facts about the world. This is also sometimes called readability.
C++ is designed to represent the world as we humans see it. It uses a mixture of symbolic logic and primitive representations that are easy for us to understand, but not necessarily computers.
LISP is designed to represent the world as it actually exists. It uses symbolic logic, which is capable of representing concepts and facts far more precisely than primitive representations.
Here, I'll explain why LISP is more expressive. Do you know what a function is? It's simply a rule that transforms one input to another output. For example, you might have the function f(x) = x^2.
Do you know what a predicate is? It's an expression that evaluates to either true or false. For example, you might have the predicate x^2 > y.
Log in:
You are getting an AI to generate text on different topics.
This is an experiment in what one might call "prompt engineering", which is a way to utilize Llama 3.1 405b, a neural network trained by Meta.
Llama is a language model. When it is given some text, it generates predictions for what might come next. It is remarkably good at adapting to different contexts, as defined by a prompt (in this case, hidden), which sets the scene for what type of text will be generated.
Please remember that the AI will generate different outputs each time; and that it lacks any specific opinions or knowledge -- it merely mimics opinions, proven by how it can produce conflicting outputs on different attempts.
Feel free to share interesting outputs to /r/philosopherAI on Reddit.