Getting started with basic transportation problems like Wolf, Cabbage, Goat with either C# or F# [closed]

StackOverflow https://stackoverflow.com/questions/11473756

  •  20-06-2021
  •  | 
  •  

Pergunta

OK. this might be a very basic question to please don't flame me but I have been googling I want to learn how to write solutions to transportation problems like Wolf, Cabbage, and Goat or traveling salesman using F#

so far my research has taken me to these resources on the web

http://mat.gsia.cmu.edu/orclass/integer/integer.html

http://www.zib.de/Publications/Reports/SC-95-27.pdf

Fox-Goat-Cabbage Transportation

http://www.qauprogrammers.com/Article/File-192324030/PROLOG-Programming-with-NET

but despite reading thru these, I have not been able to "think" on how should such a problem be solved in F# type of language

Foi útil?

Solução

I'd recommend going thru the excellent article Escape from Zurg: An Exercise in Logic Programming. Although the functional language of choice there is Haskell, it should give you enough ideas about programming of optimal search problems functionally.

Also Escape from Zurg in Scala has full source code easily portable to F#.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top