<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Abhishek Shukla &#187; F#</title>
	<atom:link href="http://www.abhishekshukla.com/category/f/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.abhishekshukla.com</link>
	<description>This is one stop shop for technology and gadget information</description>
	<lastBuildDate>Sun, 28 Apr 2013 05:30:54 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
		<item>
		<title>F# : Application and Module Basics</title>
		<link>http://www.abhishekshukla.com/f/f-application-and-module-basics/</link>
		<comments>http://www.abhishekshukla.com/f/f-application-and-module-basics/#comments</comments>
		<pubDate>Wed, 30 May 2012 21:03:45 +0000</pubDate>
		<dc:creator>Abhishek</dc:creator>
				<category><![CDATA[F#]]></category>
		<category><![CDATA[Application]]></category>
		<category><![CDATA[Module]]></category>

		<guid isPermaLink="false">http://www.abhishekshukla.com/?p=2860</guid>
		<description><![CDATA[&#160; &#160; Guys, In this post i am going to talk about about the F# application structure. If you have worked with any programming languge then i would expect you to know that modules are the building blocks of an application which form the structure of an application. These are the container that contain the [...]]]></description>
				<content:encoded><![CDATA[<p style="float:right; margin:0 0 10px 15px; width:240px;">
		<img src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/115.png" width="240" title="F# : Application and Module Basics" alt="115 F# : Application and Module Basics" />
		</p><p>&nbsp;</p>
<p>&nbsp;</p>
<p>Guys,</p>
<p>In this post i am going to talk about about the F# application structure.</p>
<ul>
<li>If you have worked with any programming languge then i would expect you to know that modules are the building blocks of an application which form the structure of an application. These are the container that contain the F# functions, types and values. We could also think of a module as a static clas in C#</li>
<li>If F# we could have multiple modules in the same code file but one module could not span multiple code files.</li>
<li>A module lives in the .Net namespace hierachy. This could be controlled by the programmer as to where does the module resides in the .Net namespace hierarchy. If we are writing a simple F# program we might not see modules being cretaed as that is taken care by the F# comipler internally. Also as you would expect from F# having really good inference capbility, it automatically recognizes the entry function (main function) and structures it.</li>
<li>If we have multiple possible entry points in the F# application then we need to use the [&lt;EntryPoint&gt;] attribute to define the entry point of the program manually do that the F# compiler recognozes where to start.</li>
<li>Let see this action. Add the following code to an F# application and run it. We ould see something like the below screen:</li>
</ul>
<p>&nbsp;</p>
<div id="attachment_2861" class="wp-caption alignnone" style="width: 306px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/114.png"><img class="size-medium wp-image-2861" title="Run F# Function " src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/114-296x300.png" alt="114 296x300 F# : Application and Module Basics" width="296" height="300" /></a><p class="wp-caption-text">Run F# Function</p></div>
<ul>
<li> Now lets add a new module in this application. Right click on the project name and select add new item and add a new F# sourcefile and name it Calcy.fs</li>
</ul>
<div id="attachment_2862" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/213.png"><img class="size-medium wp-image-2862" title="Add New Item F#" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/213-300x112.png" alt="213 300x112 F# : Application and Module Basics" width="300" height="112" /></a><p class="wp-caption-text">Add New Item F#</p></div>
<p>&nbsp;</p>
<div id="attachment_2863" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/311.png"><img class="size-medium wp-image-2863" title="Add New F# Source File" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/311-300x137.png" alt="311 300x137 F# : Application and Module Basics" width="300" height="137" /></a><p class="wp-caption-text">Add New F# Source File</p></div>
<ul>
<li> Once you hit ok, you would see that the new file is cretaed and the it starts with <strong>Module Calcy</strong>. Lets do one thing lets cut the first 2 lines of code from our program.fs and paste it below module Calcy in Calcy.fs</li>
</ul>
<div id="attachment_2864" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/44.png"><img class="size-medium wp-image-2864" title="F# Module" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/44-300x179.png" alt="44 300x179 F# : Application and Module Basics" width="300" height="179" /></a><p class="wp-caption-text">F# Module</p></div>
<ul>
<li> Now in Program.fs we we would see that the compiler is complaining. So what we need to do is prefix the intAdd function with our module name like below:</li>
</ul>
<div id="attachment_2865" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/54.png"><img class="size-medium wp-image-2865" title="Call Function from another module" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/54-300x75.png" alt="54 300x75 F# : Application and Module Basics" width="300" height="75" /></a><p class="wp-caption-text">Call Function from another module</p></div>
<ul>
<li> But you can see that the error still persists. Wonder why? Its because F# evaluates functions as well as files in the order they appear. So as the Calcy.fs is present below the program.fs in solution explorer we cannot use the functions present in Calcy module. So just right click the Calcy.fs file and click on move up and you see the error disappear from your Program.fs file. We could run the application and see that it works absolutly fine.</li>
</ul>
<div id="attachment_2866" class="wp-caption alignnone" style="width: 308px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/64.png"><img class="size-medium wp-image-2866" title="Move File Up F#" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/64-298x300.png" alt="64 298x300 F# : Application and Module Basics" width="298" height="300" /></a><p class="wp-caption-text">Move File Up F#</p></div>
<ul>
<li>The F# compiler would still automatically create a module from the program.fs file but if want you refer it from a from program in other .Net language then we should know the name of the module and hence it is a good idea to give the module in Prorogram.fs a name. So change the code in Program.fs as below:</li>
</ul>
<div id="attachment_2867" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/71.png"><img class="size-medium wp-image-2867" title="F# EntryPoint" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/71-300x128.png" alt="71 300x128 F# : Application and Module Basics" width="300" height="128" /></a><p class="wp-caption-text">F# EntryPoint</p></div>
<ul>
<li> Now here we have multiple things to note. We have specified the module name. We have specified that this main function is the entry point to our application. Also you would see that i have specified a return value of <strong>0</strong> for the main function. This return value is required as the main method expects a return value of type int.</li>
<li>Now lets modify the Calcy.fs and make it contain 2 modules. You would still see that there is an error which expects us to specify a namspace so that distintion can be made between the modules.</li>
</ul>
<div id="attachment_2868" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/81.png"><img class="size-medium wp-image-2868" title="Multiple Modules in 1 File F#" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/81-300x99.png" alt="81 300x99 F# : Application and Module Basics" width="300" height="99" /></a><p class="wp-caption-text">Multiple Modules in 1 File F#</p></div>
<ul>
<li> Lets add the namspace as global and change the code accordingly in Program.fs as the module names have changed and run the app and it should work fine.</li>
</ul>
<div id="attachment_2869" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/91.png"><img class="size-medium wp-image-2869" title="namespace global F#" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/91-300x223.png" alt="91 300x223 F# : Application and Module Basics" width="300" height="223" /></a><p class="wp-caption-text">namespace global F#</p></div>
<p>&nbsp;</p>
<div id="attachment_2870" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/101.png"><img class="size-medium wp-image-2870" title="Run F# App" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/101-300x197.png" alt="101 300x197 F# : Application and Module Basics" width="300" height="197" /></a><p class="wp-caption-text">Run F# App</p></div>
<ul>
<li> Now if we want to use any other custom namespace other than the global namespace then we need to open that namespace before we can use it otherwise the F# complier will complain. In F# we could also just opn the module instead of the whole namespace and this is an extention the using keyword in the C# language. This gives use the flexibility to remove the module name suffix before the intAdd funstion in Program.fs</li>
</ul>
<div id="attachment_2871" class="wp-caption alignnone" style="width: 233px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/115.png"><img class="size-medium wp-image-2871" title="Custom Namespace F#" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/115-223x300.png" alt="115 223x300 F# : Application and Module Basics" width="223" height="300" /></a><p class="wp-caption-text">Custom Namespace F#</p></div>
<ul>
<li> If we modify Program.fs module to be part of the same namespace as Calcy.fs modules we do not need to open the namespace which makes perfect sence.</li>
</ul>
<p>You can find the source code for this post <a target="_blank" href="http://i.minus.com/1338498178/ePpgfWxcXqp0-W5KX3LYIg/dJheYi1cgzYD9/ApplicationAndModules.zip">here</a></p>
<p>&nbsp;</p>
<p><strong>Any questions, comments an feedback are welcome.</strong></p>
<p>&nbsp;</p>
<div style="min-height:33px;" class="really_simple_share really_simple_share_button robots-nocontent snap_nopreview"><div class="really_simple_share_facebook_like" style="width:100px;"><iframe src="//www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.abhishekshukla.com%2Ff%2Ff-application-and-module-basics%2F&amp;send=false&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;height=27&amp;locale=en_US" 
							scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:27px;" allowTransparency="true"></iframe></div><div class="really_simple_share_twitter" style="width:100px;"><a target="_blank" href="https://twitter.com/share" class="twitter-share-button" data-count="horizontal" 
						data-text="F# : Application and Module Basics" data-url="http://www.abhishekshukla.com/f/f-application-and-module-basics/" 
						data-via=""  ></a></div><div class="really_simple_share_google1" style="width:80px;"><div class="g-plusone" data-size="medium" data-href="http://www.abhishekshukla.com/f/f-application-and-module-basics/" ></div></div></div>
		<div style="clear:both;"></div>]]></content:encoded>
			<wfw:commentRss>http://www.abhishekshukla.com/f/f-application-and-module-basics/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>F# : Create and Call Functions</title>
		<link>http://www.abhishekshukla.com/f/f-create-and-call-functions/</link>
		<comments>http://www.abhishekshukla.com/f/f-create-and-call-functions/#comments</comments>
		<pubDate>Mon, 28 May 2012 17:29:04 +0000</pubDate>
		<dc:creator>Abhishek</dc:creator>
				<category><![CDATA[F#]]></category>
		<category><![CDATA[Function]]></category>

		<guid isPermaLink="false">http://www.abhishekshukla.com/?p=2849</guid>
		<description><![CDATA[&#160; Guys, In this one i am gonna talk about how we can create and call functions in F#. In F# functions are also values which is evident because they use the same syntax with the let keyword as assignments. When you are writing functions that span multiple lines you need to use indentation to define the function [...]]]></description>
				<content:encoded><![CDATA[<p style="float:right; margin:0 0 10px 15px; width:240px;">
		<img src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/63.png" width="240" title="F# : Create and Call Functions" alt="63 F# : Create and Call Functions" />
		</p><p>&nbsp;</p>
<p>Guys,</p>
<p>In this one i am gonna talk about how we can create and call functions in F#.</p>
<ul>
<li>In F# functions are also values which is evident because they use the same syntax with the <strong>let</strong> keyword as assignments.</li>
<li>When you are writing functions that span multiple lines you need to use indentation to define the function structure.</li>
<li>Functions are nestable in F#.</li>
<li>In F# we don&#8217;t need to expliclitly define the return value of the function. The last expression which is evaluated in the function would become the function&#8217;s return value automatically.</li>
<li>As you have already seen in the previous posts that the inference engine of F# is pretty great and as you would expect input parameters and return values are inferred automatically by the compiler and hence the signature of the function is when we are calling a function in F# automatically defined.</li>
<li>When we are calling a function in F# we don&#8217;t need to put any delimiters. We need to use the parentheses for specifying priority only for we are making nested calls.</li>
<li>Lets declare a function and follow it with space and followed by the parameter followed by the evaluation and followed by the return value.</li>
</ul>
<div id="attachment_2854" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/113.png"><img class="size-medium wp-image-2854" title="int Square" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/113-300x139.png" alt="113 300x139 F# : Create and Call Functions" width="300" height="139" /></a><p class="wp-caption-text">int Square</p></div>
<ul>
<li> Now lets create a function with two input parameters. Now this function will be a multi line function. keep in mind when you are writing a multi line function then indentation is very important and if you do not follow the indentation then you might get the following warning.</li>
</ul>
<div id="attachment_2851" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/212.png"><img class="size-medium wp-image-2851" title="F# Function Indentation" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/212-300x70.png" alt="212 300x70 F# : Create and Call Functions" width="300" height="70" /></a><p class="wp-caption-text">F# Function Indentation</p></div>
<ul>
<li> Now lets talk about the add function. As you could see in the image below when i take my mouse over to the intAdd function then we see that <strong>intAdd is a value if type int which goes to int goes to int. </strong> Let me explain what i mean by that. Add is a value of type int as all values in F# have a type. int goes to int goes to int means there are are two int parameters coming in and one int value coming out. It might seem odd to you that the two int inputs are separated by the go to operator but thats how it is in F# as all the functions are in carried format. We would talk more about that later.</li>
</ul>
<div id="attachment_2855" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/310.png"><img class="size-medium wp-image-2855" title="int Add Function F#" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/310-300x143.png" alt="310 300x143 F# : Create and Call Functions" width="300" height="143" /></a><p class="wp-caption-text">int Add Function F#</p></div>
<ul>
<li> As you know that functions are just values we could nest them according to our requirement. Lets create a new function intAddNested. Here intAddNested is the function and we have nested a value inside it with result as the return value.</li>
</ul>
<div id="attachment_2856" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/43.png"><img class="size-medium wp-image-2856" title="Nested Function F#" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/43-300x143.png" alt="43 300x143 F# : Create and Call Functions" width="300" height="143" /></a><p class="wp-caption-text">Nested Function F#</p></div>
<ul>
<li> Now lets call the function that we just created. We dont need to use paranthesis in the same way as we don&#8217;t need to use the paranthesis while declaring the function. To call the function just type the following code in your F# program. Here add5and3 is the name of the type and the call to the function is followed by the =.</li>
</ul>
<div id="attachment_2857" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/53.png"><img class="size-medium wp-image-2857" title="Function Call F#" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/53-300x160.png" alt="53 300x160 F# : Create and Call Functions" width="300" height="160" /></a><p class="wp-caption-text">Function Call F#</p></div>
<ul>
<li> Now lets see how we can use the return value from one function in the call to the other function. Here we could see we have used the return value of the intSquare function in intAdd function. As in standard maths the part of the function call inside the paranthesis is called first and then the other part o fthe function is executed.</li>
</ul>
<div id="attachment_2858" class="wp-caption alignnone" style="width: 297px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/63.png"><img class="size-full wp-image-2858" title="Multi Function Call F#" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/63.png" alt="63 F# : Create and Call Functions" width="287" height="67" /></a><p class="wp-caption-text">Multi Function Call F#</p></div>
<ul>
<li> You can select all the code and send it to interactive to evaluate your code.</li>
</ul>
<p>You can find the source code of this post <a target="_blank" href="http://i.minus.com/1338490959/4eN_sWCYaONIFYZU0X10hg/dbdrTCxsKElnRC/FSharpFunctions.zip">here</a></p>
<p>Any questions, comments and feedback are most welcome.</p>
<div style="min-height:33px;" class="really_simple_share really_simple_share_button robots-nocontent snap_nopreview"><div class="really_simple_share_facebook_like" style="width:100px;"><iframe src="//www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.abhishekshukla.com%2Ff%2Ff-create-and-call-functions%2F&amp;send=false&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;height=27&amp;locale=en_US" 
							scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:27px;" allowTransparency="true"></iframe></div><div class="really_simple_share_twitter" style="width:100px;"><a target="_blank" href="https://twitter.com/share" class="twitter-share-button" data-count="horizontal" 
						data-text="F# : Create and Call Functions" data-url="http://www.abhishekshukla.com/f/f-create-and-call-functions/" 
						data-via=""  ></a></div><div class="really_simple_share_google1" style="width:80px;"><div class="g-plusone" data-size="medium" data-href="http://www.abhishekshukla.com/f/f-create-and-call-functions/" ></div></div></div>
		<div style="clear:both;"></div>]]></content:encoded>
			<wfw:commentRss>http://www.abhishekshukla.com/f/f-create-and-call-functions/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>F# : Values, Data Types and Type Inference</title>
		<link>http://www.abhishekshukla.com/f/f-values-data-types-and-type-inference/</link>
		<comments>http://www.abhishekshukla.com/f/f-values-data-types-and-type-inference/#comments</comments>
		<pubDate>Thu, 24 May 2012 15:15:50 +0000</pubDate>
		<dc:creator>Abhishek</dc:creator>
				<category><![CDATA[F#]]></category>
		<category><![CDATA[Data Types]]></category>
		<category><![CDATA[Type Inference]]></category>
		<category><![CDATA[Values]]></category>

		<guid isPermaLink="false">http://www.abhishekshukla.com/?p=2842</guid>
		<description><![CDATA[&#160; &#160; Hey Guys, In this post i am going to talk about Values, Data Types and Types Inferences in F#. &#160; Values in F# are what Variables are in some other languages. They are declared and assigned using the keyword &#8220;let&#8221;. By default simple values are immutable and thats the reason why they are [...]]]></description>
				<content:encoded><![CDATA[<p style="float:right; margin:0 0 10px 15px; width:240px;">
		<img src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/62.png" width="240" title="F# : Values, Data Types and Type Inference" alt="62 F# : Values, Data Types and Type Inference" />
		</p><p>&nbsp;</p>
<p>&nbsp;</p>
<p>Hey Guys,</p>
<p>In this post i am going to talk about Values, Data Types and Types Inferences in F#.</p>
<p>&nbsp;</p>
<p>Values in F# are what Variables are in some other languages. They are declared and assigned using the keyword &#8220;let&#8221;. By default simple values are immutable and thats the reason why they are not called variables. Their types are automatically inffered automatically by assignment. But this does not mean that F# is a dynamic language. It is still a statically typed language but its just that the type inference works so well that you would rarely find any explicitly assigned types. For litrels F# has a complete list of the suffixes available. Some of them are u for uint, y for byte, L for int64, l for bigint, m for decimal and so on.</p>
<p>If you would have worked with any of the programming languages you would know that a variable is used to hold a value. F# has variable as well but it also has values which are not similar to variables so they cannot be chaged at runtime.</p>
<p>You can declare a variable in F# by sinpmly writing</p>
<p>let  myVariable = 100</p>
<p>and now when you hover over the mouse on the variable you would see that F# has inferred it as int. But we cannot chage the value of myVariable and when we try to assign a value to the  myVariable then the compile would give a warning that it would expect the value comparision instead of a new assignment to value of  myVariable.</p>
<div id="attachment_2845" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/52.png"><img class="size-medium wp-image-2845" title="Immuteable Variable" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/52-300x53.png" alt="52 300x53 F# : Values, Data Types and Type Inference" width="300" height="53" /></a><p class="wp-caption-text">Immuteable Variable</p></div>
<p>The compiler is catually comparing if myVariable has value 111 and its not reassigning it. Also if you try to reassign the value of myVariable saying</p>
<p>let myVariable = 111 then we will get an error that the definition of myVariable is being duplicated.</p>
<p>But if you try to do the same thing in the interactive enviorment (for details of how to use the interactive enviorment visit <a href="http://www.abhishekshukla.com/f/repl-read-eval-print-loop-in-f/">F# Interactive enviorment/</a>) it would work fine as the interactive enviorment is designed to work for the evaluation and revaluation. But this will not work in the application context.</p>
<p>Now let type the different types of values for different variables and mouse over over them and see how they are inferred.</p>
<div id="attachment_2846" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/62.png"><img class="size-medium wp-image-2846" title="Data Types in F#" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/62-300x271.png" alt="62 300x271 F# : Values, Data Types and Type Inference" width="300" height="271" /></a><p class="wp-caption-text">Data Types in F#</p></div>
<p>You could take your mouse over each of the variables and could see the way it is inferred and type other types as well and see if they are correctly inferred or not.</p>
<p>So we can see that the standard value types in F# are not muteable..</p>
<p>Any Comments, Questions and Feedback are most welcome&#8230;</p>
<div style="min-height:33px;" class="really_simple_share really_simple_share_button robots-nocontent snap_nopreview"><div class="really_simple_share_facebook_like" style="width:100px;"><iframe src="//www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.abhishekshukla.com%2Ff%2Ff-values-data-types-and-type-inference%2F&amp;send=false&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;height=27&amp;locale=en_US" 
							scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:27px;" allowTransparency="true"></iframe></div><div class="really_simple_share_twitter" style="width:100px;"><a target="_blank" href="https://twitter.com/share" class="twitter-share-button" data-count="horizontal" 
						data-text="F# : Values, Data Types and Type Inference" data-url="http://www.abhishekshukla.com/f/f-values-data-types-and-type-inference/" 
						data-via=""  ></a></div><div class="really_simple_share_google1" style="width:80px;"><div class="g-plusone" data-size="medium" data-href="http://www.abhishekshukla.com/f/f-values-data-types-and-type-inference/" ></div></div></div>
		<div style="clear:both;"></div>]]></content:encoded>
			<wfw:commentRss>http://www.abhishekshukla.com/f/f-values-data-types-and-type-inference/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>F# : Interactive Enviorment or REPL (Read Eval Print Loop)</title>
		<link>http://www.abhishekshukla.com/f/repl-read-eval-print-loop-in-f/</link>
		<comments>http://www.abhishekshukla.com/f/repl-read-eval-print-loop-in-f/#comments</comments>
		<pubDate>Thu, 24 May 2012 08:57:22 +0000</pubDate>
		<dc:creator>Abhishek</dc:creator>
				<category><![CDATA[F#]]></category>
		<category><![CDATA[Interactive Enviorment]]></category>
		<category><![CDATA[REPL]]></category>

		<guid isPermaLink="false">http://www.abhishekshukla.com/?p=2834</guid>
		<description><![CDATA[&#160; In this post we would talk about REPL which is the provided by the F# interactive enviorment. It could be used as tool window inside Visual studio or as stand alone command line application. Its really useful  as we can evaluate the Code within the Visual Studio enviorment easily. It can used during or before [...]]]></description>
				<content:encoded><![CDATA[<p style="float:right; margin:0 0 10px 15px; width:240px;">
		<img src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/42.png" width="240" title="F# : Interactive Enviorment or REPL (Read Eval Print Loop)" alt="42 F# : Interactive Enviorment or REPL (Read Eval Print Loop)" />
		</p><p>&nbsp;</p>
<p>In this post we would talk about REPL which is the provided by the F# interactive enviorment. It could be used as tool window inside Visual studio or as stand alone command line application. Its really useful  as we can evaluate the Code within the Visual Studio enviorment easily. It can used during or before editing the code in the editor. Lets see how this works.</p>
<ul>
<li>Create a new F# application and add the following code to it.</li>
</ul>
<div id="attachment_2835" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/111.png"><img class="size-medium wp-image-2835" title="F# App" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/111-300x88.png" alt="111 300x88 F# : Interactive Enviorment or REPL (Read Eval Print Loop)" width="300" height="88" /></a><p class="wp-caption-text">F# App</p></div>
<ul>
<li>The use of the interactive enviorment is pretty easy. Just right click on the first line of code and select &#8211; Send to Interactive.</li>
</ul>
<div id="attachment_2836" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/211.png"><img class="size-medium wp-image-2836" title="F# Send To Interactive" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/211-300x116.png" alt="211 300x116 F# : Interactive Enviorment or REPL (Read Eval Print Loop)" width="300" height="116" /></a><p class="wp-caption-text">F# Send To Interactive</p></div>
<ul>
<li> It will automatically bring up the interactive window within the F# enviorment and evalute the selected line of code.</li>
</ul>
<div id="attachment_2837" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/39.png"><img class="size-medium wp-image-2837" title="F# interactive" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/39-300x172.png" alt="39 300x172 F# : Interactive Enviorment or REPL (Read Eval Print Loop)" width="300" height="172" /></a><p class="wp-caption-text">F# interactive</p></div>
<ul>
<li>We can also type in the interactive window for evaluatig the code, but once we type the code to evaluate and hit enter the evaluation will not start so we need to terminate the code line with two semi colons and press enter. As F# does not have its own line termination but in the intercation window we need to treminate the statement with two semi colons. Once you press enter you would see the statement is evaluated and the interactive tool tells you the variable delared is an integer with value as 100.</li>
</ul>
<div id="attachment_2838" class="wp-caption alignnone" style="width: 170px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/42.png"><img class="size-full wp-image-2838" title="F# Interaction Line Ternination" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/42.png" alt="42 F# : Interactive Enviorment or REPL (Read Eval Print Loop)" width="160" height="110" /></a><p class="wp-caption-text">F# Interaction Line Ternination</p></div>
<ul>
<li> Now you can evaluate almost any F# code using the Interactive evaluation there and some restriction on the automatic evaluation. Now if you evalute a System.Console.ReadLine, it would work perfectly fine but if you select all the code written above in the Program.fs and send it to interactive the Console.ReadLine would retrieve an empty string. So we need to to careful at some places withis tool.</li>
<li>The compile langauages before F# did not had this capability so its really nice to have this stuff but you need to be careful while using it.</li>
</ul>
<p>Any feedback, comments and questions are requeted.</p>
<div style="min-height:33px;" class="really_simple_share really_simple_share_button robots-nocontent snap_nopreview"><div class="really_simple_share_facebook_like" style="width:100px;"><iframe src="//www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.abhishekshukla.com%2Ff%2Frepl-read-eval-print-loop-in-f%2F&amp;send=false&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;height=27&amp;locale=en_US" 
							scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:27px;" allowTransparency="true"></iframe></div><div class="really_simple_share_twitter" style="width:100px;"><a target="_blank" href="https://twitter.com/share" class="twitter-share-button" data-count="horizontal" 
						data-text="F# : Interactive Enviorment or REPL (Read Eval Print Loop)" data-url="http://www.abhishekshukla.com/f/repl-read-eval-print-loop-in-f/" 
						data-via=""  ></a></div><div class="really_simple_share_google1" style="width:80px;"><div class="g-plusone" data-size="medium" data-href="http://www.abhishekshukla.com/f/repl-read-eval-print-loop-in-f/" ></div></div></div>
		<div style="clear:both;"></div>]]></content:encoded>
			<wfw:commentRss>http://www.abhishekshukla.com/f/repl-read-eval-print-loop-in-f/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>F# : WPF Hello World</title>
		<link>http://www.abhishekshukla.com/f/f-wpf-hello-world/</link>
		<comments>http://www.abhishekshukla.com/f/f-wpf-hello-world/#comments</comments>
		<pubDate>Tue, 22 May 2012 07:14:07 +0000</pubDate>
		<dc:creator>Abhishek</dc:creator>
				<category><![CDATA[F#]]></category>

		<guid isPermaLink="false">http://www.abhishekshukla.com/?p=2797</guid>
		<description><![CDATA[&#160; Hope you guys had a look at my other F# posts In this post i am going to talk about how we can create a Hello World program in WPF using F#. We would need to manually create and include XAML files in WPF projects, they could also be loaded from code at runtime. [...]]]></description>
				<content:encoded><![CDATA[<p style="float:right; margin:0 0 10px 15px; width:240px;">
		<img src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WPFHelloWorld6-1024x627.png" width="240" title="F# : WPF Hello World" alt="WPFHelloWorld6 1024x627 F# : WPF Hello World" />
		</p><p>&nbsp;</p>
<p>Hope you guys had a look at my other F# <a href="http://www.abhishekshukla.com/category/f/">posts</a></p>
<p>In this post i am going to talk about how we can create a Hello World program in WPF using F#.</p>
<p>We would need to manually create and include XAML files in WPF projects, they could also be loaded from code at runtime. We would also need to write the code to hook up event handlers. Let&#8217;s get started.</p>
<ul>
<li>Create a new F# application named HelloWorldWPF</li>
</ul>
<p>&nbsp;</p>
<div id="attachment_2798" class="wp-caption alignnone" style="width: 1005px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WPFHelloWorld1.png"><img class="size-full wp-image-2798" title="Create WPF F# Project" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WPFHelloWorld1.png" alt="WPFHelloWorld1 F# : WPF Hello World" width="995" height="695" /></a><p class="wp-caption-text">Create WPF F# Project</p></div>
<ul>
<li>There is no way add a xaml file to a console application so either you would need to create an xml file and start editing it or use any other tool (Like Expression Blend) to create a xaml file and then include it in the project. i have used the 2nd option</li>
</ul>
<div id="attachment_2799" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WPFHelloWorld2.png"><img class="size-medium wp-image-2799" title="F# Add XAML File" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WPFHelloWorld2-300x155.png" alt="WPFHelloWorld2 300x155 F# : WPF Hello World" width="300" height="155" /></a><p class="wp-caption-text">F# Add XAML File</p></div>
<ul>
<li> You can have a look at the xaml file below:</li>
</ul>
<div id="attachment_2800" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WPFHelloWorld3.png"><img class="size-medium wp-image-2800" title="F# XAML File" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WPFHelloWorld3-300x172.png" alt="WPFHelloWorld3 300x172 F# : WPF Hello World" width="300" height="172" /></a><p class="wp-caption-text">F# XAML File</p></div>
<ul>
<li>Lets add the references required by the WPF application. Add a reference to PresentationCore, PresentationFramework, System.Data, System.Deployment</li>
<li>Open namespace System, System.Windows and System.Windows.Controls. The let keyword is used for simple values.</li>
<li>Create a function that will load my main windows. So lets create a function named loadMyWindow().</li>
<li>Then define a new Uri for loading our MainWindow.xaml. This is the standard .Net specification. We don&#8217;t need any line terminatio as F# terminaties lines automatically.</li>
<li>Then we create a window using the resource loaded in the resourceLocator and then we need to cast this to Window using the F# cast operator.</li>
<li>The we find Element which is our clickButton and and we add a function to the Click Event of the Button. In F# we need to also handle all the return vales and hence we have used F# helper function <strong>ignore</strong> to ignore the values. In F# the last keyword in the function is the return type of the fuction which in our case is a window.</li>
<li>Now we would pass this window to the Application.Run and we ignore the retun value as well. We also then apply the STAThread attribute.</li>
</ul>
<div id="attachment_2802" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WPFHelloWorld51.png"><img class="size-medium wp-image-2802" title="WPF HelloWorld" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WPFHelloWorld51-300x143.png" alt="WPFHelloWorld51 300x143 F# : WPF Hello World" width="300" height="143" /></a><p class="wp-caption-text">WPF HelloWorld</p></div>
<ul>
<li> Now we run the application and this is what we see.</li>
</ul>
<div id="attachment_2803" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WPFHelloWorld6.png"><img class="size-medium wp-image-2803" title="WPF HelloWorld" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WPFHelloWorld6-300x183.png" alt="WPFHelloWorld6 300x183 F# : WPF Hello World" width="300" height="183" /></a><p class="wp-caption-text">WPF HelloWorld</p></div>
<p>&nbsp;</p>
<p>Any Feedback, comments or questions were most welcome.</p>
<div style="min-height:33px;" class="really_simple_share really_simple_share_button robots-nocontent snap_nopreview"><div class="really_simple_share_facebook_like" style="width:100px;"><iframe src="//www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.abhishekshukla.com%2Ff%2Ff-wpf-hello-world%2F&amp;send=false&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;height=27&amp;locale=en_US" 
							scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:27px;" allowTransparency="true"></iframe></div><div class="really_simple_share_twitter" style="width:100px;"><a target="_blank" href="https://twitter.com/share" class="twitter-share-button" data-count="horizontal" 
						data-text="F# : WPF Hello World" data-url="http://www.abhishekshukla.com/f/f-wpf-hello-world/" 
						data-via=""  ></a></div><div class="really_simple_share_google1" style="width:80px;"><div class="g-plusone" data-size="medium" data-href="http://www.abhishekshukla.com/f/f-wpf-hello-world/" ></div></div></div>
		<div style="clear:both;"></div>]]></content:encoded>
			<wfw:commentRss>http://www.abhishekshukla.com/f/f-wpf-hello-world/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>F# : Hello World with Windows Forms (Winforms)</title>
		<link>http://www.abhishekshukla.com/f/f-hello-world-with-windows-forms-winforms/</link>
		<comments>http://www.abhishekshukla.com/f/f-hello-world-with-windows-forms-winforms/#comments</comments>
		<pubDate>Tue, 22 May 2012 03:33:29 +0000</pubDate>
		<dc:creator>Abhishek</dc:creator>
				<category><![CDATA[F#]]></category>
		<category><![CDATA[hello world]]></category>
		<category><![CDATA[Winforms]]></category>

		<guid isPermaLink="false">http://www.abhishekshukla.com/?p=2788</guid>
		<description><![CDATA[&#160; Hope you guys had a look at my previous F# post In this post i would be talking about using F# in a Windows Forms application. You should know that there is no designer support for F# so our necessity is to construct Form from  code. Standard Mechanishm like Data Binding work well with F# [...]]]></description>
				<content:encoded><![CDATA[<p style="float:right; margin:0 0 10px 15px; width:240px;">
		<img src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WinFormsHelloWorld5-1024x519.png" width="240" title="F# : Hello World with Windows Forms (Winforms)" alt="WinFormsHelloWorld5 1024x519 F# : Hello World with Windows Forms (Winforms)" />
		</p><p>&nbsp;</p>
<p>Hope you guys had a look at my previous F# <a href="http://www.abhishekshukla.com/f/f-hello-world-console-application/">post</a></p>
<p>In this post i would be talking about using F# in a Windows Forms application. You should know that there is <strong>no designer support</strong> for <strong>F#</strong> so our necessity is to construct Form from  code. <strong>Standard Mechanishm</strong> like <strong>Data Binding</strong> <strong>work</strong> well with <strong>F#</strong> types.</p>
<ul>
<li>Create a new F# application using Visual Studio named WinFormsHello</li>
</ul>
<div id="attachment_2789" class="wp-caption alignnone" style="width: 758px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WinFormsHelloWorld1.png"><img class=" wp-image-2789" title="F# Project" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WinFormsHelloWorld1.png" alt="WinFormsHelloWorld1 F# : Hello World with Windows Forms (Winforms)" width="748" height="621" /></a><p class="wp-caption-text">F# Project</p></div>
<p>&nbsp;</p>
<ul>
<li>Go to the references of the application and add a reference to System.Windows.forms and System.Drawing</li>
</ul>
<div id="attachment_2790" class="wp-caption alignnone" style="width: 767px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WinFormsHelloWorld2.png"><img class=" wp-image-2790" title="F# Add Reference" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WinFormsHelloWorld2.png" alt="WinFormsHelloWorld2 F# : Hello World with Windows Forms (Winforms)" width="757" height="898" /></a><p class="wp-caption-text">F# Add Reference</p></div>
<p>&nbsp;</p>
<ul>
<li>Lets open a namespace System.Windows.Forms. This will have the members of this namespace available for me here without having to reference them again and again.</li>
</ul>
<div id="attachment_2791" class="wp-caption alignnone" style="width: 688px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WinFormsHelloWorld3.png"><img class="size-full wp-image-2791" title="Open Winforms Namespace in F#" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WinFormsHelloWorld3.png" alt="WinFormsHelloWorld3 F# : Hello World with Windows Forms (Winforms)" width="678" height="260" /></a><p class="wp-caption-text">Open Winforms Namespace in F#</p></div>
<p>&nbsp;</p>
<ul>
<li>Declare a simple datatype to work with. This particular data types are called as record in F# and when F# recognizes a data type it would use it just like a system data type.</li>
<li>Now we create an array of this record type that we just declared. You would see that semi colons are used as separators here. And if you would have worked in C# this declaration might seem a little different to you, so bear with it. The array starts with opening square bracket and a pipe [| and ends with pipe and a closing Square Bracket |].</li>
<li> Now lets create a new form. Now you should keep in mind that F# wants you (as a convention) to use the new keyword for a type if that type implements iDisposable interface. Else we can leave the new keyword. Also you could see that i have passed a named parameter in Form instantiation. Now what this will do is create an instance of Form for me and then try to assign value to the Text Property of the form.</li>
<li>Now let&#8217;s create a new DataGrid and make its source as myEmployees collection. Also lets add the datagrid to the forms controls.</li>
<li>Now let&#8217;s pass the form as a parameter to Application.Run command.</li>
</ul>
<div id="attachment_2792" class="wp-caption alignnone" style="width: 818px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WinFormsHelloWorld4.png"><img class="size-full wp-image-2792" title="WinForms HelloWorld" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WinFormsHelloWorld4.png" alt="WinFormsHelloWorld4 F# : Hello World with Windows Forms (Winforms)" width="808" height="538" /></a><p class="wp-caption-text">WinForms HelloWorld</p></div>
<p>&nbsp;</p>
<ul>
<li>When we run this application we are able to see our Form with the DataGridView</li>
</ul>
<div id="attachment_2793" class="wp-caption alignnone" style="width: 876px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WinFormsHelloWorld5.png"><img class=" wp-image-2793" title="WinForms HelloWorld" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/WinFormsHelloWorld5.png" alt="WinFormsHelloWorld5 F# : Hello World with Windows Forms (Winforms)" width="866" height="582" /></a><p class="wp-caption-text">WinForms HelloWorld</p></div>
<p>&nbsp;</p>
<p>Any Feedback, comments or questions are always welcome.</p>
<div style="min-height:33px;" class="really_simple_share really_simple_share_button robots-nocontent snap_nopreview"><div class="really_simple_share_facebook_like" style="width:100px;"><iframe src="//www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.abhishekshukla.com%2Ff%2Ff-hello-world-with-windows-forms-winforms%2F&amp;send=false&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;height=27&amp;locale=en_US" 
							scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:27px;" allowTransparency="true"></iframe></div><div class="really_simple_share_twitter" style="width:100px;"><a target="_blank" href="https://twitter.com/share" class="twitter-share-button" data-count="horizontal" 
						data-text="F# : Hello World with Windows Forms (Winforms)" data-url="http://www.abhishekshukla.com/f/f-hello-world-with-windows-forms-winforms/" 
						data-via=""  ></a></div><div class="really_simple_share_google1" style="width:80px;"><div class="g-plusone" data-size="medium" data-href="http://www.abhishekshukla.com/f/f-hello-world-with-windows-forms-winforms/" ></div></div></div>
		<div style="clear:both;"></div>]]></content:encoded>
			<wfw:commentRss>http://www.abhishekshukla.com/f/f-hello-world-with-windows-forms-winforms/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>F# : Hello World Console Application</title>
		<link>http://www.abhishekshukla.com/f/f-hello-world-console-application/</link>
		<comments>http://www.abhishekshukla.com/f/f-hello-world-console-application/#comments</comments>
		<pubDate>Mon, 21 May 2012 12:24:01 +0000</pubDate>
		<dc:creator>Abhishek</dc:creator>
				<category><![CDATA[F#]]></category>
		<category><![CDATA[Console App]]></category>
		<category><![CDATA[hello world]]></category>

		<guid isPermaLink="false">http://www.abhishekshukla.com/?p=2777</guid>
		<description><![CDATA[&#160; Hey guys, I am always exited to learn something new and hope you guys feel the same way. Today i am going to share as to how we can write a Hello World console application in F#. Hope you have VS 2010 installed. Go to File &#8211;&#62; New Project Navigate to Other languages &#8211;&#62; [...]]]></description>
				<content:encoded><![CDATA[<p style="float:right; margin:0 0 10px 15px; width:240px;">
		<img src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/61.png" width="240" title="F# : Hello World Console Application" alt="61 F# : Hello World Console Application" />
		</p><p>&nbsp;</p>
<p>Hey guys,</p>
<p>I am always exited to learn something new and hope you guys feel the same way. Today i am going to share as to how we can write a Hello World console application in F#. Hope you have VS 2010 installed.</p>
<ul>
<li>Go to File &#8211;&gt; New Project</li>
</ul>
<p><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/110.png"><img class="alignnone size-medium wp-image-2778" title="F#" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/110-300x201.png" alt="110 300x201 F# : Hello World Console Application" width="300" height="201" /></a></p>
<ul>
<li>Navigate to Other languages &#8211;&gt; F# &#8211;&gt; Windows &#8211;&gt; F# Application
<div id="attachment_2779" class="wp-caption alignnone" style="width: 310px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/210.png"><img class="size-medium wp-image-2779" title="New F# Project" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/210-300x203.png" alt="210 300x203 F# : Hello World Console Application" width="300" height="203" /></a><p class="wp-caption-text">New F# Project</p></div>
<p>&nbsp;</li>
<li> If you open the references tab you could see a reference to FSharp.Core</li>
</ul>
<p>&nbsp;</p>
<div id="attachment_2780" class="wp-caption alignnone" style="width: 459px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/38.png"><img class="size-full wp-image-2780" title="FSharp.Core" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/38.png" alt="38 F# : Hello World Console Application" width="449" height="347" /></a><p class="wp-caption-text">FSharp.Core</p></div>
<div class="mceTemp"></div>
<ul>
<li>
<div class="mceTemp">Now write the following code in program.fs file. You will see that i have added comments along all the lines to explain what each line does.</p>
<div id="attachment_2781" class="wp-caption alignnone" style="width: 1129px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/41.png"><img class="size-full wp-image-2781" title="Code for F# Hello World Console App" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/41.png" alt="41 F# : Hello World Console Application" width="1119" height="463" /></a><p class="wp-caption-text">Code for F# Hello World Console App</p></div>
</div>
</li>
<li>
<div class="mceTemp">
<div class="mceTemp">Press control F5 and you would see the following screen</p>
<div id="attachment_2782" class="wp-caption alignnone" style="width: 774px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/51.png"><img class="size-full wp-image-2782" title="Console Screen" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/51.png" alt="51 F# : Hello World Console Application" width="764" height="202" /></a><p class="wp-caption-text">Console Screen</p></div>
</div>
</div>
</li>
<li>
<div class="mceTemp">
<div class="mceTemp">
<div class="mceTemp">Enter some text and press Enter Key and you would see the screen below:</p>
<div id="attachment_2783" class="wp-caption alignnone" style="width: 800px"><a href="http://www.abhishekshukla.com/wp-content/uploads/2012/05/61.png"><img class="size-full wp-image-2783" title="Console Screen" src="http://www.abhishekshukla.com/wp-content/uploads/2012/05/61.png" alt="61 F# : Hello World Console Application" width="790" height="211" /></a><p class="wp-caption-text">Console Screen</p></div>
</div>
</div>
</div>
</li>
</ul>
<div class="mceTemp">
<div class="mceTemp">
<div class="mceTemp"></div>
<div class="mceTemp">Any comments, feedback or questions are more than welcome.</div>
</div>
</div>
<div class="mceTemp">
<div class="mceTemp"></div>
</div>
<div class="mceTemp"></div>
<p class="mceTemp">
<div style="min-height:33px;" class="really_simple_share really_simple_share_button robots-nocontent snap_nopreview"><div class="really_simple_share_facebook_like" style="width:100px;"><iframe src="//www.facebook.com/plugins/like.php?href=http%3A%2F%2Fwww.abhishekshukla.com%2Ff%2Ff-hello-world-console-application%2F&amp;send=false&amp;layout=button_count&amp;width=100&amp;show_faces=false&amp;action=like&amp;colorscheme=light&amp;height=27&amp;locale=en_US" 
							scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:27px;" allowTransparency="true"></iframe></div><div class="really_simple_share_twitter" style="width:100px;"><a target="_blank" href="https://twitter.com/share" class="twitter-share-button" data-count="horizontal" 
						data-text="F# : Hello World Console Application" data-url="http://www.abhishekshukla.com/f/f-hello-world-console-application/" 
						data-via=""  ></a></div><div class="really_simple_share_google1" style="width:80px;"><div class="g-plusone" data-size="medium" data-href="http://www.abhishekshukla.com/f/f-hello-world-console-application/" ></div></div></div>
		<div style="clear:both;"></div>]]></content:encoded>
			<wfw:commentRss>http://www.abhishekshukla.com/f/f-hello-world-console-application/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
