title: Event driven design in c
body: <p>this is a little theoretical question.
  Imagine a device full of sensors. Now, in case a sensor x detects something, something should happen. Meanwhile, in case something else is detected, like two sensors detects two different things, then, this device must behave differently.</p>
  
  <p>From webdesign (so javascript) I learned about Events, for example (using jquery) <code>$(".x").on("click", function(){})</code> or from angularjs <code>$scope.watch("name_of_var", function())</code>.</p>
  
  <p>Is there any possibility to replicate this behaviour in C, without using complex libraries?</p>
  
  <p>Thanks.</p>