When I install swift correctly, according to the website, I get an error code while trying "swift --version" and there is no error code when I do "swift" it just goes to another line.

The symptom of running swift without arguments and it "just goes to another line" is caused by missing the exact version of Python. For Swift 5.3.3 release it requires Python 3.9. Python 3.8 or earlier will not work.

To verify this is the case, type echo %ERRORLEVEL% after running swift. If you get -1073741515, this is 0xc0000135 which is the Windows status STATUS_DLL_NOT_FOUND. What's happening is swift.exe is executing lldb.exe, which is loading a DLL which requires python39.dll to be in your path.

See my post for more details.