Category talk:Programming Tasks: Difference between revisions

no edit summary
No edit summary
No edit summary
Line 37:
 
This task demonstrates examples of the producer-consumer pattern in the chosen language. There are several variations on the producer-consumer pattern including synchronous, asynchronous, bounded queue, and unbounded queue. The simplest implementation of a producer-consumer has one producing task or thread and one consuming task or thread. More complex implementations may have 1..P producers and 1..C consumers. The number of producers and consumers need not be the same. A producer-consumer implementation may require that every data item produced by the producer(s) must be consumed exactly once by one of the consumers, or it may require that the consumer(s) only sample the data produced by the producer(s). An example of a sampling application might be an automated weather station. The weather station may produce temperature readings at a rate of 100Hz while the consumer displaying those readings on a website may only display changes at a rate of 1Hz. The consumer only needs to display one reading per second and can ignore 99 readings every second.
 
== Is there '''''Prime Triplets''''' task? ==
 
Prime triplets are p1, p2 and p3 where p2 = p1 + 2, p3 = p2 + 2 and p1,p2 and p3 are primes. Is exist this task?
2,468

edits