Does there exist a programming language, where you always are guaranteed a termination?
If you only have if/else statements can you then be sure that that a program will terminate?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Yes, of course there are some non-Turing-complete languages that do guarantee a termination (or at least provide subsets with such a guarantee):
In most cases, it is achieved by only allowing recursive calls over strict sub-terms (and, with Church arithmetics, it implies always decreasing positive integer counters as well).
And, surprisingly, this is not as limiting as it looks, and these languages are perfectly suitable for a very wide range of problems.
The Terminator project could be interesting as well.