title: Can I use a global variable to synchronize request in node express?
body: <p>I want to check if a request path is used for the first time.</p>
  
  <p>Do nodejs monothreaded model insure following code will work the way it is intended ? Is there any possible case where this code could send "<strong>you are the first one</strong>" more than once ? </p>
  
  <pre><code>const express = require('express')
  const app = express()
  
  let FIRST = true
  
  app.get("/", function(req, res) {   
      res.send("you are "+(FIRST?'':'not')+" the first one")
      FIRST = false       
  });
  
  app.listen(8080, function(){});
  </code></pre>