title: Which version of C# am I using
body: <p>I want to find out which version of C# I'm using.
  If I would be using python I would do something like <code>python -V</code> from the command line, or type:</p>
  
  <pre><code>import sys
  print sys.version
  </code></pre>
  
  <p>In PHP I would do something like this: <code>phpinfo();</code> in java: <code>java -version</code></p>
  
  <p>But I was not able to find how to achieve this in C#.</p>
  
  <p><a href="https://stackoverflow.com/q/1331715/1090562">This question</a> does not answer it, although the name suggests that it should.</p>
  
  <p>I got that it depends on the .NET framework, but is there a programmatic way of figuring out my framework? I mean without going to the directory and checking the name of my .NET folders.</p>