Talk:Nondeterministic programming

Please move this article to Nondeterministic programming (note the lower-case in the second word.) -- 192.250.34.161 15:53, 22 June 2007 (UTC)[reply]

The title of the article doesn't make it obvious that this is talking about a nondeterministic programming paradigm. Is this different than behavior that is non-deterministic? If so, the article should make some mention and contrast the two. E.g. a multi-threaded or multi-process program that shares state, but doesn't do anything to synchronize reads/writes. —Preceding unsigned comment added by 131.107.0.77 (talk) 23:41, 16 December 2009 (UTC)[reply]

As an example, I'd cite "Select" in Go language. Permit me to quote extensively from the language spec[1]:
A "select" statement chooses which of a set of possible communications will proceed. It looks similar to a "switch" statement but with the cases all referring to communication operations.
For all the send and receive expressions in the "select" statement, the channel expressions are evaluated in top-to-bottom order, along with any expressions that appear on the right hand side of send expressions. A channel may be nil, which is equivalent to that case not being present in the select statement except, if a send, its expression is still evaluated. If any of the resulting operations can proceed, one of those is chosen and the corresponding communication and statements are evaluated. [snip]
If multiple cases can proceed, a pseudo-random fair choice is made to decide which single communication will execute.
Here the Go language explicitly specifies a non-determinism in program flow, requiring the runtime to make a psuedo-random fair choice pick of which communication to proceed with: mandated, specified nondeterminism.
--Rektide (talk) 02:31, 5 October 2010 (UTC)[reply]
See also [2] for a Scala implementation and Nondeterministic algorithm for an algorithmic understanding.
--Rektide (talk) 18:49, 1 December 2010 (UTC)[reply]

Limited number of alternatives?

A programmer specifies a limited number of alternatives, but the program must later choose between them.

Isn't it possible for there to be an infinite number of alternatives? Like this

(define (natural-number)
  (let loop ((n 1))
    (amb n (loop (+ n 1)))))

(natural-number) ===> 1
(amb) ===> 2
(amb) ===> 3
(amb) ===> 4
(amb) ===> 5
(amb) ===> 6
;;; and so on...

122.57.250.105 (talk) 22:14, 28 July 2016 (UTC)[reply]

Content Disclaimer

Informasi ini disarikan dari Wikipedia dan disajikan kembali untuk tujuan edukasi. Konten tersedia di bawah lisensi CC BY-SA 3.0. Kami tidak bertanggung jawab atas ketidakakuratan data yang bersumber dari kontribusi publik tersebut.

  1. The information displayed on this website is sourced in part or in whole from Wikipedia and has been adapted for the purpose of restating it. We strive to provide accurate and relevant information, however:
  2. There is no guarantee of absolute accuracy. Wikipedia is an open, collaborative project that can be edited by anyone, so information is subject to change.
  3. It is not intended to constitute professional advice. The content displayed is for informational and educational purposes only. For important decisions (e.g., medical, legal, or financial), please consult a professional.
  4. Content copyright. Wikipedia is licensed under the Creative Commons Attribution-ShareAlike License (CC BY-SA). This means that content may be reused with appropriate attribution and shared under a similar license.
  5. Responsible use. Any risk arising from the use of information from this website is entirely the responsibility of the user.