======================================== Tarea 1: Solve the problem of producer/consumer fixed size buffer using shared memory and counting semaphores. Your program must be designed to work continuously, but would be compiled for say 50 messages. A simple floating point number for each message would be fine. You should make the size of the buffer and the number of messages to be transmitted defined in a header file. You should use usleep() to simulate a slow consumer and a slow producer to test both extremes. It should be possible for the consumer and producer to access the buffer simultaneously, as long as it is not full or empty. ======================================== Tarea 2: Solve the multiple reader / multiple writer problem. You should give priority to writers, so that as soon as a writer arrives, ALL arriving readers will have to wait, but all that have already entered can continue. When a reader enters, he must check to see if there are any writers, and if so, put himself to sleep, otherwise, enter immediately. When a writer enters, he must check to see if there are other writers or reader, and if so put himself to sleep. When a reader leaves, he must see if he is the last reader inside, and if so check for waiting writers, and wake one up if there is at least one. A writer on leaving, must check to see if there is another writer waiting, and if so wake one up, if not wake up ALL waiting readers. ========================================