Question

If you were to read a problem statement, such as something found on TopCoder, and you converted it to a lambda calculus representation, is it a simple exercise to 'convert' this to Haskell or Lisp code?

In other words, can a problem be solved using the lambda calculus formal system and then trivially implemented in a functional programming language?

Était-ce utile?

La solution

The syntax for Haskell is quite similar to the lambda calculus. Your problem is going to be that some terms in the untyped lambda calculus won't be accepted by Haskell's type checker.

Out of curiosity, who the hell solves TopCoder using the lambda calculus? That sounds highly non-trivial. o_O

Autres conseils

That's a difficult question. In theory, yes. In practice, sort of. In general, I would say that defined computable functions can be efficiently-implemented (in the time-space of programmer effort), yes, but it really depends on the familiarity with the programming language and the mathematics in question over the possibility of doing so. For example, I suppose one could implement a lambda calculus interpreter, and I direct you to ['Visual Automata Simulator]'1 for an example of Turing's model contained in a trivializing wrapper.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top