1 / 7

Az F# programozási nyelv

Az F# programozási nyelv. Drenyovszki Rajmund Elektrotechnika és Kibernetika Szakcsoport drenyovszki.rajmund@gamf.kefo.hu. Mi ez?. Programozási nyelv, .NET keretrendszer része, Funkcionális, HOGYAN helyett a MIT. Újabb programozási nyelv?. Assembly, Basic, Pascal, C, C++, Java, C#, …

huyen
Télécharger la présentation

Az F# programozási nyelv

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Az F# programozási nyelv Drenyovszki Rajmund Elektrotechnika és Kibernetika Szakcsoport drenyovszki.rajmund@gamf.kefo.hu

  2. Mi ez? • Programozási nyelv, • .NET keretrendszer része, • Funkcionális, • HOGYAN helyett a MIT.

  3. Újabb programozási nyelv? • Assembly, Basic, Pascal, C, C++, Java, C#, … • Lisp, Haskell, Erlang, OCaml, F# • A VisualStudio része, teljes .NET elérhető vele, de kicsit más szemlélettel.

  4. Példa(C#) … public int negyzet(int x) { return x * x; } public int negyzetOsszeg(int[] szamok) { int osszeg = 0; foreach (int i in szamok) { int x = negyzet(i); osszeg = osszeg + x; } return osszeg; } …

  5. Példa (F#) let negyzet x = x * x let negyzetOsszeg szamok = let mutable osszeg = 0 for i in szamok do let x = negyzet i osszeg <- osszeg + x osszeg

  6. Példa (funkcionális F#) let functionalisNegyzetOsszeg szamok = szamok |> Seq.map (fun x -> x * x) |> Seq.sum

  7. Könyvek • [1] D. Syme, A. Granicz, A. Cisternino: Expert F#, Apress (2007). • [2] J. Harrop: F# for scientists, John Wiley & Sons, Inc. (2008). • [3] C. Smith: Programming F#, O’Reilly Media, Inc. (2010).

More Related