I remember using this language in the AI class, i thought it was an old, deprecated language as people now use python mainly, really cool to see it again
I forget who said it, but a good programming language should have two features:
1. Make simple problems easy.
2. Make difficult problems possible.
Python is an outstanding language on both scores.
Prolog, alas, is much better at #2 than it is at #1. For example, prolog is a great choice for writing domain-specific languages, and modern implementations (like scryer prolog, mentioned in a comment above), can generate very efficient code for them.
Prolog's "killer ap" is how well it does on a third feature:
3. It makes virtually impossible tasks "merely" very difficult ;-)
And it has a steep learning curve; it took me years to really "get" it, and I only persevered because I was facing one of those category #3 problems.
Its not a deprecated language, but alas, it is destined to be a niche language. But for those niches, it is still the best, hands-down.
I guess this is rather category #2 than #3, but my favorite example is Advent of Code 2021, day 24: https://adventofcode.com/2021/day/24. I think many people consider this one of the hardest AOC problems ever and at the time many people didn't even code up a complete solution but solved in manually (me included). However, with Prolog it's almost trivial. So many of Prologs strengths come together here: writing parsers, writing interpreters, solving integer constraints, and in particular "reasoning backwards".
I was writing a theorem prover for higher-order modal logic. All the theorem provers written in C or C++ were tens of thousands of lines, and even at that they had only a fraction of what I needed. What's more, they were all like 100 times *slower* at proving theorems which prolog could prove out of the box.
So I decided to try to implement the features I needed on top of the theorem prover which prolog already is.
Took me forever, but eventually it all came together like a thunderclap, and I was able to implement a theorem prover for quantified, higher-order modal logic which was amazingly-blazingly fast--in 67 lines of prolog.
In terms of lines-of-code per day, its the least productive I've ever been :-)
While I wouldn’t want to do many tasks in prolog. I’ve always wished for a good interop with some other language, or a language with some kind of async prolog call. There are so many things that are a couple dozen of lines of prolog but would be hundreds of lines of other languages.
I think it is undergoing a resurgence due to the LLM prolifereating, but I haven't seen how Prolog is being used in the LLM creation. Of course, I don't really understand the whole process of the creation. I do remember someone on a academic/programmer forum stating Prolog regarding research was big in academics in Europe whereas Lisp was more popular in America academics for research. It would make sense as Richard Stallman was big into AI Lisp as a consultant.
1. Make simple problems easy.
2. Make difficult problems possible.
Python is an outstanding language on both scores.
Prolog, alas, is much better at #2 than it is at #1. For example, prolog is a great choice for writing domain-specific languages, and modern implementations (like scryer prolog, mentioned in a comment above), can generate very efficient code for them.
Prolog's "killer ap" is how well it does on a third feature:
3. It makes virtually impossible tasks "merely" very difficult ;-)
And it has a steep learning curve; it took me years to really "get" it, and I only persevered because I was facing one of those category #3 problems.
Its not a deprecated language, but alas, it is destined to be a niche language. But for those niches, it is still the best, hands-down.