This documentation is a release candidate of the specification of the 2.0 release of F# made by Microsoft Research and the Microsoft Developer Division in April 2010. Discrepancies may exist between this specification and the 2.0 implementation. Som
F#Labb
设置
Installera dotnet版本5。 Testaföljandeoch se att at a testengårigenom och ettettar。
dotnet restore --interactive
dotnet build
dotnet test
N#defärgjort testa att starta F#交互式med: dotnet fsi 。 (Föratt komma ur det skriv #quit;; )
拉巴
Funderap
锋利的
有用的参考
创建一个项目
终端:使用以下命令创建项目目录
dotnet new console -lang "F#" -o projectname
将目录更改为项目,并使用以下命令运行默认版本
dotnet run
简单程序
可以将简单程序编码到文本编辑器中,如果在突出显示所有代码alt+enter的情况下使用以下命令正确安装和配置了VS-Code,
递归函数
句法:
// Recursive function def:
let rec function - name param