Check out example codes for "How do I see which version of Swift I'm using". It will help you in understanding the concepts better.

Code Example 1

// Open the Terminal and write:

swift -version

Learn ReactJs, React Native from akashmittal.com