您的位置:首页 > 其它

F#的一些资源:书、blog、video以及例程

2010-03-15 14:06 906 查看

Quick Links:

Download the F# February 2010 CTP (release info) or VS2010 RC

Download the F# October 2009 CTP(release info)

Learn F#

The F# Language Specification (PDF)

MSDN docs for F# (language reference, library reference)

F# Programming at Wikibooks (there are lots of samples)

F# Programming Language at Wikipedia

F# Code Samples at MSDN ("The F# Samples")

F# Projects at CodePlex

F# Forums

F# Community Blogs

Blogs

Don Syme

Robert Pickering

hubFS

F# News

Tomas Petricek

Brian McNamara

Videos:

An Introduction to Microsoft F#

Don Syme (talk and demo of F#)

C9 Bytes: Data Visualization and F# with Luke Hoban

Don Syme: What's new in F# - Asynchronous Workflows (and welcome to the .NET family!)

Luke Hoban on Channel9

More...

Hello World Samples:

Sample 1, Sample 2, Sample 3, Sample 4, Fibonacci Numbers

Good Books:

Foundations of F# (Expert's Voice in .Net) by Robert Pickering (May, 2007)

Expert F# (Expert's Voice in .Net) by Don Syme (Dec, 2007)

Beginning F# by Robert Pickering (coming)

F# For Scientists by Dr Jon Harrop (Aug, 2008)

The Definitive Guide to F# by Don Syme (coming)

Real World Functional Programming by Tomas Petricek

Programming F# by Chris Smith (Oct, 2009)

// C# :
// using System;
open System
// say hello wrold
printfn "Hello, World! What is your name, user?"
// C# :
// var name = Console.ReadLine();
let name = Console.ReadLine()
// C# :
// public delegate void SaySomethingDelegate(string toWho);
// SaySomethingDelegatesayHello =
//     who => Console.WriteLine("Hello, {0}!", who);
let sayHello who = printfn "Hello, %s!" who
// hi
sayHello name
// you can using .NET Framework classes and methods:
let sayHelloDotNet who =
Console.WriteLine("Hello from F# via .Net, " + name + "!")
// hello again!
sayHelloDotNet name
// let's count Fibonacci
let rec fib i =
match i with
| 1 | 2 -> 1
| i -> fib(i-1) + fib(i-2)

// result
printfn "%i" (fib 20)
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐