Tutorial by Examples

with other sets # Intersection {1, 2, 3, 4, 5}.intersection({3, 4, 5, 6}) # {3, 4, 5} {1, 2, 3, 4, 5} & {3, 4, 5, 6} # {3, 4, 5} # Union {1, 2, 3, 4, 5}.union({3, 4, 5, 6}) # {1, 2, 3, 4, 5, 6} {1, 2, 3, 4, 5} | {3, 4, 5, 6} # {1, 2, 3, 4, 5, 6} # Difference ...
<input type="button" value="Button Text"> Buttons can be used for triggering actions to occur on the page, without submitting the form. You can also use the <button> element if you require a button that can be more easily styled or contain other elements: <butt...
In order to exit Vim, first make sure you are in Normal mode by pressing Esc. :q Enter (will prevent you from exiting if you have unsaved changes - short for :quit) To discard changes and exit Vim: :q! Enter to force exit and discard changes (short for :quit!, not to be confused with :!q), ...
Substitutability is a principle in object-oriented programming introduced by Barbara Liskov in a 1987 conference keynote stating that, if class B is a subclass of class A, then wherever A is expected, B can be used instead: class A {...} class B extends A {...} public void method(A obj) {...} ...
You can set the timezone that will be used by Django in the settings.py file. Examples: TIME_ZONE = 'UTC' # use this, whenever possible TIME_ZONE = 'Europe/Berlin' TIME_ZONE = 'Etc/GMT+1' Here is the list of valid timezones When running in a Windows environment this must be set to the same a...
Deploying an advanced project template to shared hosting is a bit trickier than a basic one because it has two webroots, which shared hosting webservers don't support. We will need to adjust the directory structure so frontend URL will be http://site.local and backend URL will be http://site.local/a...
Go to Install Neo4j which should detect the OS platform via your web browser, download and follow the usual installation instructions for your OS. Neo4j was created with Java, therefore will run on any platform with Java installed, however the Neo4j team has simplified installation by providing eas...
Today Fortran is mainly used for numerical computation. This very simple example illustrates the basic program structure to solve quadratic equations: program quadratic !a comment !should be present in every separate program unit implicit none real :: a, b, c real :: discriminant...
A button can be disabled by Swift myButton.isEnabled = false Objective-C: myButton.enabled = NO; The button will become gray: If you don't want the button appearance to change when disabled set adjustsImageWhenDisabled to false / NO
Swift label.backgroundColor = UIColor.redColor() label.backgroundColor = .redColor() Swift 3 label.backgroundColor = UIColor.red Objective-C label.backgroundColor = [UIColor redColor];
Often we want to operate only on elements of an array that fulfill a specific condition: Select Will return elements that match a specific condition array = [1, 2, 3, 4, 5, 6] array.select { |number| number > 3 } # => [4, 5, 6] Reject Will return elements that do not match a specific c...
manifest.json gives information about the extension, such as the most important files and the capabilities that the extension might use. Among the supported manifest fields for extensions, the following three are required. { "manifest_version": 2, "name": "My Exte...
Suppose you have defined the following Person class: public class Person { String name; int age; public Person (int age, String name) { this.age = age; this.name = name; } } If you instantiate a new Person object: Person person = new Person(25, &qu...
Introduction SharePoint 2016 is the version 16 release of the SharePoint product family. It was released on May 4, 2016. This example covers the installation of SharePoint 2016 using the Single Server Farm configuration. This configuration covers the basics of setting up a SharePoint farm without t...
Create a new file named hello_world.dart with the following content: void main() { print('Hello, World!'); } In the terminal, navigate to the directory containing the file hello_world.dart and type the following: dart hello_world.dart Hit enter to display Hello, World! in the terminal wi...
Detailed instructions on getting ironpython set up or installed. Install IronPython Just download the newest version from http://ironpython.net and follow the instructions from the msi package. This package will setup everything you need to start working with ironpython.
#include <stdlib.h> #include <lauxlib.h> #include <lua.h> #include <lualib.h> int main(void) { lua_State *lvm_hnd = lua_open(); luaL_openlibs(lvm_hnd); /* Load a standard Lua function from global table: */ lua_getglobal(lvm_hnd, "print&quot...
CommandDescription<Esc>Leaves insert mode, triggers autocommands and abbreviations<C-[>Exact synonymous of <Esc><C-c>Leaves insert mode, doesn't trigger autocommands Some people like to use a relatively uncommon pair of characters like jk as shortcut for <Esc> or <C...
There are 4 looping constructs in Rust. All examples below produce the same output. Infinite Loops let mut x = 0; loop { if x > 3 { break; } println!("{}", x); x += 1; } While Loops let mut x = 0; while x <= 3 { println!("{}", x); x += 1; ...
As mentioned in Basics, we can use anything which implements IntoIterator with the for loop: let vector = vec!["foo", "bar", "baz"]; // vectors implement IntoIterator for val in vector { println!("{}", val); } Expected output: foo bar baz ...

Page 117 of 1336