title: VB .NET Shared Function if called multiple times simultaneously
body: <p>Consider I have a shared function:-</p>
  
  <pre><code>Public Shared Function CalculateAreaFromRadius(ByVal radius As Double) As Double
  
      ' square the radius...
      Dim radiusSquared As Double
      radiusSquared = radius * radius
  
      ' multiply it by pi...
      Dim result As Double
      result = radiusSquared * Math.PI
  
      'Wait a bit, for the sake of testing and 
      'simulate another call will be made b4 earlier one ended or such
       for i as Integer = 0 to integer.Max
       Next
  
      ' return the result...
      Return result
  
  End Function
  </code></pre>
  
  <p>My Questions:</p>
  
  <ol>
  <li><p>If I have two or more threads in the same vb .net app and each of them calls the shared function at the same time with different RADIUS, will they each get their own AREA? </p></li>
  <li><p>I want to know for each call to the function if it is using same local variables or each call creates new instances of local variables?</p></li>
  <li><p>Will the answers to above questions be same If I have multiple (2+) single threaded apps and they all call the function at the same time with different RADIUS value?</p></li>
  </ol>
  
  <p>I will appreciate your reponse. Thank you.</p>