Tutorial by Examples: l

decimal literals are defined by using the suffix M or m on a real number: decimal m = 30.5M;
double literals are defined by using the suffix D or d, or by using a real number: double d = 30.5D;
float literals are defined by using the suffix F or f, or by using a real number: float f = 30.5F;
long literals are defined by using the suffix L or l, or by using an integral values within the range of long: long l = 5L;
ulong literals are defined by using the suffix UL, ul, Ul, uL, LU, lu, Lu, or lU, or by using an integral values within the range of ulong: ulong ul = 5UL;
short type has no literal. Integer literals are implicitly converted from int: short s = 127;
ushort type has no literal suffix. Integer literals are implicitly converted from int: ushort us = 127;
bool literals are either true or false; bool b = true;
let rec factorial n = match n with | 0 | 1 -> 1 | n -> n * (factorial (n - 1)) This function matches on both the values 0 and 1 and maps them to the base case of our recursive definition. Then all other numbers map to the recursive call of this function.
boot -d seancorfield/boot-new new -t app -n <appname> This command will tell boot to grab the task boot-new from https://github.com/seancorfield/boot-new and execute the task with the app template (see link for other templates). The task will create a new directory called <appname> wi...
Consider the following C# code Expression<Func<int, int>> expression = a => a + 1; Because the C# compiler sees that the lambda expression is assigned to an Expression type rather than a delegate type it generates an expression tree roughly equivalent to this code ParameterExpres...
document.getElementsByClassName('class-name') will retrieve <a class="class-name">Any</a> <b class="class-name">tag</b> <div class="class-name an-extra-class">with that class.</div> If no existing elements contain the given c...
Basics Anonymous functions are a powerful tool of the MATLAB language. They are functions that exist locally, that is: in the current workspace. However, they do not exist on the MATLAB path like a regular function would, e.g. in an m-file. That is why they are called anonymous, although they can h...
Complete the Installation and setup part. This will create the project in Firebase console and will also install the base SDK in your Android App. Add the dependency for Firebase Realtime Database to your app-level build.gradle file: compile 'com.google.firebase:firebase-database:9.4.0' N...
<link rel="stylesheet" href="test.css" media="print"> Media specifies what style sheet should be used for what type of media. Using the print value would only display that style sheet for print pages. The value of this attribute can be any of the mediatype val...
This will create a folder with the same name as the project, i.e. /My.Project.Name $ git tfs clone http://tfs:8080/tfs/DefaultCollection/ $/My.Project.Name
Cloning from a git repository is ten times faster than cloning directly from TFVS and works well in a team environment. At least one team member will have to create the bare git repository by doing the regular git-tfs clone first. Then the new repository can be bootstrapped to work with TFVS. $ git...
The following assumes you will use kdiff3 for file diffing and although not essential it is a good idea. C:\> choco install kdiff3 Git can be installed first so you can state any parameters you wish. Here all the Unix tools are also installed and 'NoAutoCrlf' means checkout as is, commit as i...
This is a common gotcha with Laravel routes. Routes are matched in the order that they are declared. The first matching route is the one that is used. This example will work as expected: Route::get('/posts/{postId}/comments/{commentId}', 'CommentController@show'); Route::get('/posts/{postId}', 'P...
Unlike the other helpers, this one uses static class helpers to serialize and deserialize, hence it is a little bit easier than the others to use. using Newtonsoft.Json; var rawJSON = "{\"Name\":\"Fibonacci Sequence\",\"Numbers\":[0, 1, 1, 2, 3, 5, 8, 13]}...

Page 210 of 861