<!DOCTYPE html><html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /></head><body><div data-crea="font-wrapper" style="font-family: Tahoma; font-size: 16px; direction: ltr"><div style="font-family: Tahoma; font-size: 16px"></div>Hi,<div><br></div><div>that puts me in a kind of deadlock.<br>I wanted to share and discuss my implementation (haven't done anything in Erlang for quite a while),</div><div>but I also do not want to give away a possible solution for free... </div><div>(I currently see it with my son: he learns best, if he researches the problem on his own (with some guidance)).<br><div></div><br>Maybe on a meta-level:</div><div>I think I cheated a bit:</div><div>As the agent knows which ingredients to take and which smoker can act, </div><div>he directly sends a message to the smoker who shall take the ingredients.</div><div>The smokers only wait for the message from the agent..</div><div>Therefore there is no deadlock, as far as I can see.</div><div><br>dieter</div><div><br><br><div data-anchor="reply-title">Am Mo., Nov. 9, 2020 11:53 schrieb Karolis Petrauskas <k.petrauskas@gmail.com>:</div><blockquote><div>Doing assignments? :)<br><br>Karolis<br><br>On Mon, Nov 9, 2020 at 10:16 AM AshiSh Kulkarni <<a target="_blank" href="mailto:kul2971@gmail.com" style="cursor: pointer;">kul2971@gmail.com</a>> wrote:<br><blockquote>Hello,<br>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.<br><br>Thank You.</blockquote></div></blockquote></div></div></body></html>