AW: Re: Regarding Cigarette Smoker's problem

dieter@REDACTED dieter@REDACTED
Mon Nov 9 13:39:42 CET 2020


Hi,
that puts me in a kind of deadlock.
I wanted to share and discuss my implementation (haven't done anything in Erlang for quite a while),
but I also do not want to give away a possible solution for free... 
(I currently see it with my son: he learns best, if he researches the problem on his own (with some guidance)).
Maybe on a meta-level:
I think I cheated a bit:
As the agent knows which ingredients to take and which smoker can act, 
he directly sends a message to the smoker who shall take the ingredients.
The smokers only wait for the message from the agent..
Therefore there is no deadlock, as far as I can see.

dieter
Am Mo., Nov. 9, 2020 11:53 schrieb Karolis Petrauskas :
Doing assignments? :)

Karolis

On Mon, Nov 9, 2020 at 10:16 AM AshiSh Kulkarni  wrote:
Hello,
I am new to erlang. And I  am trying to implement the Cigarette Smoker's Problem In Erlang,but i'm having some errors. So if anybody has already implemented the code in erlang, plz can you mail me ASAP.

Thank You.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20201109/0f85763c/attachment.htm>


More information about the erlang-questions mailing list