text:
Cooke and Wheatstone telegraph, five-needle
Definition
According to Wikipedia:

The Cooke and Wheatstone telegraph was an early electrical telegraph system dating from the 1830s invented by English inventor William Fothergill Cooke and English scientist Charles Wheatstone. It was the first telegraph system to be put into commercial service. The receiver consisted of a number of needles which could be moved by electromagnetic coils to point to letters on a board. This feature was liked by early users who were unwilling to learn codes, and employers who did not want to invest in staff training.

It works like this:

In the middle are five needles, which can be deflected clockwise (as is the case of the middle needle) or anti-clockwise (as is the case of the last needle).
In the picture above, the two deflected needles point to the letter G, which means that the letter being transmitted/received is the letter G.
Note that the letters C, J, Q, V, X, Z are missing and thus have to be substituted with other letters.
Task
You will receive a character in ABDEFGHIKLMNOPRSTUWY as input, and you will output the corresponding configuration of the five needles, with undeflected as |, deflected clockwise as /, and deflected anti-clockwise as \.
Testcases
This covers all the possible inputs
input output
A     /|||\
B     /||\|
D     |/||\
E     /|\||
F     |/|\|
G     ||/|\  (explanation: see above)
H     /\|||
I     |/\||
K     ||/\|
L     |||/\
M     \/|||
N     |\/||
O     ||\/|
P     |||\/
R     \|/||
S     |\|/|
T     ||\|/
U     \||/|
W     |\||/
Y     \|||/

Rules/Requirements

Each submission should be either a full program or function. If it is a function, it must be runnable by only needing to add the function call to the bottom of the program. Anything else (e.g. headers in C), must be included.
If it is possible, provide a link to a site where your program can be tested.
Your program must not write anything to STDERR.
Standard Loopholes are forbidden.
Your program can output in any case, but it must be printed (not an array or similar).

Scoring
Programs are scored according to bytes, in UTF-8 by default or a different character set of your choice.
Eventually, the answer with the least bytes will win.
Submissions
To make sure that your answer shows up, please start your answer with a headline, using the following Markdown template:
# Language Name, N bytes

where N is the size of your submission. If you improve your score, you can keep old scores in the headline, by striking them through. For instance:
# Ruby, <s>104</s> <s>101</s> 96 bytes

If there you want to include multiple numbers in your header (e.g. because your score is the sum of two files or you want to list interpreter flag penalties separately), make sure that the actual score is the last number in the header:
# Perl, 43 + 2 (-p flag) = 45 bytes

You can also make the language name a link which will then show up in the leaderboard snippet:
# [><>](http://esolangs.org/wiki/Fish), 121 bytes

Leaderboard
Here is a Stack Snippet to generate both a regular leaderboard and an overview of winners by language.

/* Configuration */

var QUESTION_ID = 87104; // Obtain this from the url
// It will be like https://XYZ.stackexchange.com/questions/QUESTION_ID/... on any question page
var ANSWER_FILTER = "!t)IWYnsLAZle2tQ3KqrVveCRJfxcRLe";
var COMMENT_FILTER = "!)Q2B_A2kjfAiU78X(md6BoYk";
var OVERRIDE_USER = 48934; // This should be the user ID of the challenge author.

/* App */

var answers = [], answers_hash, answer_ids, answer_page = 1, more_answers = true, comment_page;

function answersUrl(index) {
  return "https://api.stackexchange.com/2.2/questions/" +  QUESTION_ID + "/answers?page=" + index + "&pagesize=100&order=desc&sort=creation&site=codegolf&filter=" + ANSWER_FILTER;
}

function commentUrl(index, answers) {
  return "https://api.stackexchange.com/2.2/answers/" + answers.join(';') + "/comments?page=" + index + "&pagesize=100&order=desc&sort=creation&site=codegolf&filter=" + COMMENT_FILTER;
}

function getAnswers() {
  jQuery.ajax({
    url: answersUrl(answer_page++),
    method: "get",
    dataType: "jsonp",
    crossDomain: true,
    success: function (data) {
      answers.push.apply(answers, data.items);
      answers_hash = [];
      answer_ids = [];
      data.items.forEach(function(a) {
        a.comments = [];
        var id = +a.share_link.match(/\d+/);
        answer_ids.push(id);
        answers_hash[id] = a;
      });
      if (!data.has_more) more_answers = false;
      comment_page = 1;
      getComments();
    }
  });
}

function getComments() {
  jQuery.ajax({
    url: commentUrl(comment_page++, answer_ids),
    method: "get",
    dataType: "jsonp",
    crossDomain: true,
    success: function (data) {
      data.items.forEach(function(c) {
        if (c.owner.user_id === OVERRIDE_USER)
          answers_hash[c.post_id].comments.push(c);
      });
      if (data.has_more) getComments();
      else if (more_answers) getAnswers();
      else process();
    }
  });
}

getAnswers();

var SCORE_REG = /<h\d>\s*([^\n,]*[^\s,]),.*?(\d+)(?=[^\n\d<>]*(?:<(?:s>[^\n<>]*<\/s>|[^\n<>]+>)[^\n\d<>]*)*<\/h\d>)/;

var OVERRIDE_REG = /^Override\s*header:\s*/i;

function getAuthorName(a) {
  return a.owner.display_name;
}

function process() {
  var valid = [];

  answers.forEach(function(a) {
    var body = a.body;
    a.comments.forEach(function(c) {
      if(OVERRIDE_REG.test(c.body))
        body = '
' + c.body.replace(OVERRIDE_REG, '') + '
';
    });

    var match = body.match(SCORE_REG);
    if (match)
      valid.push({
        user: getAuthorName(a),
        size: +match[2],
        language: match[1],
        link: a.share_link,
      });

  });

  valid.sort(function (a, b) {
    var aB = a.size,
        bB = b.size;
    return aB - bB
  });

  var languages = {};
  var place = 1;
  var lastSize = null;
  var lastPlace = 1;
  valid.forEach(function (a) {
    if (a.size != lastSize)
      lastPlace = place;
    lastSize = a.size;
    ++place;

    var answer = jQuery("#answer-template").html();
    answer = answer.replace("{{PLACE}}", lastPlace + ".")
                   .replace("{{NAME}}", a.user)
                   .replace("{{LANGUAGE}}", a.language)
                   .replace("{{SIZE}}", a.size)
                   .replace("{{LINK}}", a.link);
    answer = jQuery(answer);
    jQuery("#answers").append(answer);

    var lang = a.language;
    if (/ b.lang) return 1;
    if (a.lang < b.lang) return -1;
    return 0;
  });

  for (var i = 0; i < langs.length; ++i)
  {
    var language = jQuery("#language-template").html();
    var lang = langs[i];
    language = language.replace("{{LANGUAGE}}", lang.lang)
                       .replace("{{NAME}}", lang.user)
                       .replace("{{SIZE}}", lang.size)
                       .replace("{{LINK}}", lang.link);
    language = jQuery(language);
    jQuery("#languages").append(language);
  }

}
body { text-align: left !important}

#answer-list {
  padding: 10px;
  width: 290px;
  float: left;
}

#language-list {
  padding: 10px;
  width: 290px;
  float: left;
}

table thead {
  font-weight: bold;
}

table td {
  padding: 5px;
}

<link rel="stylesheet" type="text/css" href="//cdn.sstatic.net/codegolf/all.css?v=83c949450c8b">

Leaderboard

	Author	Language	Size

Winners by Language

Language	User	Score

{{PLACE}}	{{NAME}}	{{LANGUAGE}}	{{SIZE}}	Link

{{LANGUAGE}}	{{NAME}}	{{SIZE}}	Link

C, 124 107 98 bytes
As a function:
x,i;W(char*v){for(i=strcspn(" MRUYH NSWEI OTBFK PADGL",v);x<5;++x)putchar(x^i%5?x^i/5?124:92:47);}

// main(int c,char**v){W(v[1]);}

This works by using rotating the grid 45 degrees and looking up the row/column from the resulting block.

As a full executable (107 bytes):
x;main(i,v)char**v;{for(i=strcspn(" MRUYH NSWEI OTBFK PADGL",v[1]);x<5;++x)putchar(x^i%5?x^i/5?124:92:47);}

An alternative full executable: (same bytecount but takes input from stdin and includes newline after output)
main(i){char*r=" MRUYH NSWEI OTBFK PADGL",b[]="|||||";i=strchr(r,getchar())-r;b[i%5]=47;b[i/5]=92;puts(b);}

Breakdown:
x;                                      // Implicit int declaration
main(i,v)char**v;{                      // K&R function declaration to save a byte
    for(i=strcspn("<...>",v[1]);        // Find index of input in lookup table
        x<5;++x)                        // Loop 0 to 4
        putchar(x^i%5?x^i/5?124:92:47); //  Print /, \ or | depending on value of i
}

Alternate breakdown:
main(i){
    char*r="<...>",                     // Store lookup table
    b[]="|||||";                        // Malleable base string for return
    i=strchr(r,getchar())-r;            // Find input in lookup table
    b[i%5]=47;                          // Set correct char in output to /
    b[i/5]=92;                          // Set correct char in output to \
    puts(b);                            // Print result
}

Bonus: 0-9 extension from the wikipedia page:
x;main(i,v)char**v;{for(i=strcspn(" MRUY6H NSW7EI OT8BFK P9ADGL 012345",v[1]);x<5;++x)putchar(x^i%6?x^i/6?124:92:47);}

Bonus bonus: a complete (if messy) program for both encoding and decoding messages:
#include <stdio.h>
#include <string.h>
#include <ctype.h>
#include <stdbool.h>

static const char *REF = " MRUY6H NSW7EI OT8BFK P9ADGL 012345 ";

char sub(char c) {
    c = toupper(c);
    if(c == 'C') { c = 'K'; }
    if(c == 'J') { c = 'G'; }
    if(c == 'Q') { c = 'K'; }
    if(c == 'V') { c = 'W'; }
    if(c == 'X') { c = 'S'; }
    if(c == 'Z') { c = 'S'; }
    return c;
}

void print_encoded(char c) {
    char b[] = "|||||";
    const char *p = strchr(REF, sub(c));
    if(!p) { return; }
    int i = p - REF;
    if(i) {
        if(i%6 < 5) { b[i%6] = '/'; }
        if(i/6 < 5) { b[i/6] = '\\';}
    }
    puts(b);
}

char decode(const char *m) {
    int pf = 5;
    int pb = 5;
    for(int x=0;x<5;++x) {
        if(m[x] == '/') {
            pf=x;
        } else if(m[x] == '\\') {
            pb=x;
        } else if(m[x] == '\0') {
            return '!';
        }
    }
    return REF[pb*6+pf];
}

int main(int c, const char **v) {
    int inArg;
    bool isDecode;
    if(c > 1 && (strcmp(v[1], "-h") == 0 || strcmp(v[1], "--help") == 0)) {
        printf("Usage:\n  %s [-d] [<input>]\n\n", v[0]);
        printf("Converts input to/from Cooke and Wheatstone 5-needle encoding.\n\n");
        printf("If no input arguments are given, takes input from stdin.\n\n");
        printf("Parameters:\n");
        printf("  -h --help   Displays help.\n");
        printf("  -d --decode Switches to decode mode.\n");
        printf("\n");
        return 0;
    } else if(c > 1 && (strcmp(v[1], "-d") == 0 || strcmp(v[1], "--decode") == 0)) {
        inArg = (c > 2 ? 2 : 0);
        isDecode = true;
    } else if(c > 1) {
        inArg = 1;
        isDecode = false;
    } else {
        inArg = 0;
        isDecode = false;
    }
    if(isDecode) {
        if(inArg == 0) {
            char ln[6];
            while(scanf("%5s", ln) == 1) {
                putchar(decode(ln));
            }
        } else {
            for(int p = inArg; p < c; ++p) {
                for(const char *q = v[p], *e = strchr(v[p], '\0'); q < e; q += 5) {
                    while(*q == ' ') { ++q; }
                    putchar(decode(q));
                }
            }
        }
        putchar('\n');
    } else {
        if(inArg == 0) {
            int c;
            while((c = getchar()) != EOF) {
                print_encoded(c);
            }
        } else {
            for(const char *p = v[inArg]; *p; ++p) {
                print_encoded(*p);
            }
        }
    }
    return 0;
}

CJam, 42 bytes
r"HEBAMRUYIFDNSWKGOTLP"5e!{_$"/\|"er}%_&er

Test it here
Although there's a lot of structure to the outputs I'm not entirely sure yet I can compute the results efficiently (in terms of bytes). So this is still a lookup table, but I'm generating the list of possible needle configurations via permutations of the list [0 1 2 3 4].

Python 2, 172 152 151 79 bytes
lambda x:r'/|||\/|||/\|||/|\||/||\|/||'['APONM LKIHY GFEWU DBTSR'.find(x):][:5]

No algorithm, just a lookup table.
Saved 20 bytes thanks to @LeakyNun!
Saved a byte thanks to @TheBikingViking!
Saved a whopping 72 bytes thanks to @Keeta!

You can use find instead of index for -1 byte.

If you take advantage of the overlap of the slashes, you can reduce by 72 characters to something like lambda x:r'/|||/|||/|||/|||/|||/||'['APONM LKIHY GFEWU DBTSR'.find(x):][:5]

MATL, 50 bytes
'!#$kYAqof^EZC}40iA*9n4JK?45/J~v'6Y2'\|/'Za5eioZ)!

Try it online!
Short explanation
The code decompresses the shown string ('!#$...J~v') into a string containing \, | and /; reshapes it into an array where each column corresponds to a letter; and indexes that array with the input character.
Long explanation
The compressesed string has been obtained (offline) using base-3 to base-95 encoding. The data from the challenge has been arranged into a long string of \, | and /, where each group of 5 characters corresponds to a letter. This string is interpreted as the base-3 representation of some big number, which is converted to base-95, using all printable ASCII chars as digits. The result is the compressed string that appears in the code ('!#$...J~v').
The program starts decompressing this string, that is, converting from base-95 to base-3 with alphabet \, |, /. The decompressed string is reshaped into a 5-row 2D char array, in which each column representing a letter. Let us call this array Λ. This array will be indexed using the ASCII code point of the input letter.
The array Λ includes two tricks:

It has been filled with dummy values for the five letters missing between A and Y;
It starts with L (not  A) and then proceeds circularly.

The reasons for these two tricks are as follows:

Letter A has code point 65. The last letter that needs to be handled is Y, with code point 89. So we need to handle a range of 25 values, even if some intermediate ones (such as letter C) don't exist. To facilitate indexing, the five missing letters between A and Y have been filled with a dummy representation, so they do have a column in Λ. Thus, Λ has size 5×25.

Modular indexing is used. So letter A, or number 65, is the same as 65 mod 25, that is  15. Therefore A needs to be in column 15 of Λ, B in column 16, ..., and Y in column 14.

Commented code
'!#$kYAqof^EZC}40iA*9n4JK?45/J~v'     % Compressed string (in base-95)
6Y2                                   % Predefined literal 'AB...Z': source alphabet
                                      % for decompression
'\|/'                                 % Target alphabet for decompression
Za                                    % Change of base representation (decompress)
5e                                    % Reshape into 5-row array `Λ`
i                                     % Input letter
o                                     % Convert to number (ASCII code point)
Z)                                    % Use as column index into `Λ`
!                                     % Transpose into a row. Implicitly display

05AB1E, 37 34 bytes
Code:
"/\|||"œ€JÙ•3wxìeNðƒ2xGÑäß•36BIk<è

Uses the CP-1252 encoding. Try it online!.

JavaScript (ES6), 97 89 bytes
c=>(n=`ABEHMDFINRGKOSULPTWY`.search(c),s=[...`|||||`],s[4-n%5]=`\\`,s[n>>2]=`/`,s.join``)

Edit: Saved 3 bytes by switching to a lookup table that doesn't need padding. Saved 5 bytes by setting array elements instead of trying to edit a string.
Explanation: The table ABEHMDFINRGKOSULPTWY is organised so that if you split it into 5 groups of 4 adjacent letters then each letter in the group is on the same / slant in the diagram, while if you split it into 5 groups by taking the index modulo 5 then each letter in the group is on the same \ slant in the diagram. These latter groups are in reverse order but that's easily handled by subtracting from 4. (Arranging the table so that the former groups were in reverse order cost more to fix.)

VBA, 106 bytes
Function v(s):v="|||||":p=InStr(1,v &"MRUYH NSWEI OTBFK PADGL",s):Mid(v, p\5)="\":Mid(v, (p Mod 5)+1)="/"

Final byte is enter which auto-generates End Function. With acknowledgements to the scheme @Dave devised.
Invoke in spreadsheet or in  VBA Immediate window eg with ?v("K")

Mathematica, 129 bytes
""<>(IntegerDigits[IntegerDigits[36^^3ucgb2abu46m2rewohw225q4lc6hczypueyb3,190][[LetterNumber@#]],3,5]/.{0->"|",1->"/",2->"\\"})&

Anonymous function. Takes a string as input and returns a string representing its code as output. Uses a relatively simple encoding scheme.

C, 78 bytes
i;f(x){for(i=5;i--;)putchar("|/\\|"["^\\ NXLFPH DBow{} gsyc q a"[x-65]>>i&3]);}

version shown is all printable ASCII, 79 bytes. The second \\ can be replaced by any single byte that has the same last 6 bits as the \ character 0x5C : 0x1C (if your compiler allows it), 0x9C or 0xDC.
The input character is looked up in the magic string which contains values for A to Y (including spaces for the unsupported characters CJQVX.) The character from the lookup table is interpreted as five overlapping 2-bit codes where:
01 = /   10 = \    00 or 11 = |

Commented code in test program
/*
magic string codes: bytes are 01XXXXXX
A     /|||\ 011110 ^
B     /||\| 011100 \\
D     |/||\ 001110 N
E     /|\|| 011000 X
F     |/|\| 001100 L
G     ||/|\ 000110 F
H     /\||| 010000 P
I     |/\|| 001000 H
K     ||/\| 000100 D
L     |||/\ 000010 B
M     \/||| 101111 o
N     |\/|| 110111 w
O     ||\/| 111011 {
P     |||\/ 111101 }
R     \|/|| 100111 g
S     |\|/| 110011 s
T     ||\|/ 111001 y
U     \||/| 100011 c
W     |\||/ 110001 q
Y     \|||/ 100001 a

                                     ABBCDEFGHIJKLMNOPQRSTUVWXY*/
i;f(x){for(i=5;i--;)putchar("|/\\|"["^\\ NXLFPH DBow{} gsyc q a"[x-65]>>i&3]);}

j;
main(){
  j=getchar();
  f(j);
}

Python 2, 115 111 bytes
This is a simple implementation, but it could use some golfing. Suggestions welcome.
def f(c):s=["|"]*5;a=0xdb52384ebd9f46caa72899c838d50/25**(ord(c)-65)%25;s[a/5]="/";s[a%5]="\\";return''.join(s)

Ungolfed:
def f(c):
    s = ["|"] * 5
    d = ord(c) - 65
    # 0xdb52384ebd9f46caa72899c838d50 is our lookup number
    # 0040004100304231200043322110342300120124130214000304
    # in hexadecimal
    a = 0xdb52384ebd9f46caa72899c838d50 / 25**d % 25
    s[a/5] = "/"
    s[a%5] = "\\"
    return ''.join(s)

Pyth, 27 bytes
@{.p"/|\||"x."AW
Ú/Ç\x94E\x18µð££

Replace the escapes \x94, \x18 with the corresponding bytes.
Try it online
How it works
@                                      index into this list:
  .p"/|\||"                              permutations of /|\||
 {                                       deduplicate
                                       at index:
            ."AW\nÚ/Ç\x94E\x18µð££"      compressed string: EBAHIFDNSWKGOTLPMRU
           x                       Q     index in that of input (or -1 for Y)

Pyth, 32 bytes
Without using any hard-coded lookup tables.
@o-xN\/xN\\{.p"/\|||"x-rG2"CJQVX

Try it online
How it works
@                                    index into this list:
            .p"/\|||"                  all permutations of /\|||
           {                           deduplicate
 o                                     sort by the following key for N in the list:
   xN\/                                  index of / in N
  -    xN\\                              … minus index of \ in N
                                     at index:
                       rG2             capitalized alphabet
                      -   "CJQVX"      minus CJQVX
                     x           Q     index in that of input

Ruby, 159 bytes
v=[1,2,3,4,7,8,9,13,14,19];w=v+v.map{|e|25+e};a="HEBAIFDKGLMRUYNSWOTP";b="\\/"
x=w[a.index($*[0][0])];g="|"*5;y=(x>25)?0:1;g[(x/5)%5]=b[y];g[x%5]=b[1-y];puts g

Explanation:
The positions of the deflected needles are mapped to 0..4, and thought as a  base-5 number (2 digits). For A-L, the numbers are "as is"; for M-Z, add 25 to the number. The map is from variables a to w.
Given the number corresponding to the letter, use its base-5 representation: the 5s digit for the first needle, the 1s digit for the second needle, and the 25s digit for the needles' directions.
A program to encode an entire string, instead of one character, is just a bit longer: 172 bytes.
v=[1,2,3,4,7,8,9,13,14,19];w=v+v.map{|e|25+e};a="HEBAIFDKGLMRUYNSWOTP";b="\\/"
$*[0].each_char{|c|x=w[a.index(c)];g="|"*5;y=(x>25)?0:1;g[(x/5)%5]=b[y];g[x%5]=b[1-y];puts g}

source: Stack Exchange

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/

sort: votes


text:
Tips for golfing in Fishing
I recently found out about the Fishing language, and it is now a favorite of mine. However, I'm finding it difficult to do anything cool with it, including code golf. Are there any tips for golfing with Fishing to use the least characters? And any string manipulation tricks would be cool, as I am finding that difficult in Fishing.

a and m work on strings too
Though it isn't explicitly stated in the spec, a (add) and m (multiply), at least in the official Ruby interpreter, also work on strings.
Say you had two cells with strings in them at the end of the tape, and wanted to concatenate and print them. You could do it with c:
c{{P

However, as long as you don't want to preserve the original value of your first cell, you could append the second string directly onto the first with a and avoid having to go to the end of the tape:
aP

Now let's say you want to print 20 spaces. The naive way to do it would be to simply hardcode them:
`                    `P

As long as the cell to the right is free, though, you can save 11 instructions by using m:
` `{`20`n}mP

Note, however, that due to the way Ruby works, you cannot do this with the order of the cells reversed (i.e. multiply a number by a string); that causes an error.

? doesn't need both an adjacent = and an adjacent !
This isn't explicitly stated in the spec either, but with the official interpreter, you do not need to surround a conditional (?) with both = and !; if one is not present and the condition matches it, the program will keep going in its original direction. An example:
v+CCCCCC?=CCCCCCCC
  I{`0`}! E`Zero`N
        [CCCCCCCCCCCC
         E`Not zero`N

This program prints takes a string and prints "Zero" or "Not zero", depending on whether it equals "0". You could shave off two bytes, however, by removing the = sign:
v+CCCCCC?CCCCCCCC
  I{`0`}!E`Zero`N
        [CCCCCCCCCCCC
         E`Not zero`N

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/


text:
Snakes all around
Challenge
The challenge is simple: print a snake.
You will get the length of the snake as input.
A snake of length 2 looks like this:
==(:)-

A snake of length 7 looks like this:
=======(:)-

In other words, the length of a snake is how many equal signs are before the head.
Usage
Let's say I made a C++ implementation and compiled it to ./getsnake.
I could run it like so:
$ ./getsnake 10
==========(:)-

Clarifications

Standard loopholes are disallowed.
You can get input and output in any acceptable way.
You can assume all inputs given are positive integers.
You may write a function instead of a regular program.

It's kinda useless to leave a challenge in the Sandbox for only half an hour. You did get some feedback, but it's usually best to leave it in the Sandbox for 24-72 hours. (Also, you should either flesh out the "Origins" part or remove it.)

Is a function enough or do you want a full program?

@betseg function is enough

What if the input is 0?

@Fatalize Or NaN, Infinity, any negative number, or a blank string?

@Fatalize the program will only ever get positive integers

@Peanut the program will only ever get positive integers

I'm afraid all My Squiggly Lamp answers are effortlessly portable to this.

Is zero positive?

@Peanut no, it isn't

Negative integers should cause the snake to swallow itself.

Are functions that return a string (rather than printing it) valid?

Is hardcoding the input (i.e. you have to replace "n" with the number in the program to run it) allowed, rather than taking input through stdin or equivalent?

@T.Lukin it isn't

Hexagony, 33 bytes
Not gonna win, but still cool. Might be able to get golfed more.
Try it online!
Golfed:
61}?.$)@$j;(3<./;.}l/.400;5\j;.'\

Formatted:
    6 1 } ?
   . $ ) @ $
  j ; ( 3 < .
 / ; . } l / .
  4 0 0 ; 5 \
   j ; . ' \
    . . . .

Colored (Made using Timwi's Hexagony Colorer)

Explanation:
Loop, print out "=" until the counter reaches 0.
    6 1 } ?
   . $ . . $
  . . ( . . .
 / . . } . . .
  . . . ; . .
   . . . ' .
    . . . .

Print "("
    . . . .
   . . . . .
  . . . . . .
 / ; . . . . .
  4 . . . . .
   j . . . .
    . . . .

Print ":"
    . . . .
   . . . . .
  . ; ( 3 < .
 . . . } l / .
  . . . . . .
   . . . . .
    . . . .

Print ")"
    . . . .
   . . . . .
  j . . . . .
 . . . . . . .
  . . . ; 5 \
   . . . . \
    . . . .

The above values were generated using a simple python script. However, I kind of ran out of room for the "-". So, I had to resort to more advanced tricks.
When the program prints out ")", the value of the cell isn't 41, it's 1065. Hexagony just mods the value when printing. As it turns out, (1065*1000+4)%256=44, just one away from 45, the ascii value for "-". Then, I just increment, print, and insert a @ somewhere after printing.
    . . . .
   . $ ) @ $
  j . . 3 . .
 / . . } . . .
  4 0 0 . 5 \
   . ; . . \
    . . . .

How can it be called a programming language when .j4/; is ... Print "("??? Which part of .j4/; is the print and which part is the string to print?

@Fogmeister [Part 1/2] In Hexagony, any alphabetical character sets the value of the current memory cell to the ascii value of that character. "j" has an ascii value of 106, so that is what the memory is set to. Also, and numerical characters multiply the value of the current cell by 10, then add themselves to it (this allows for easy construction of numbers, like the 61 at the beginning.

[Part 2/2] So, j4 sets the memory cell to 1064. When the IP reaches the "/", it gets reflected into ";", which prints out the ascii character corresponding to the current memory cell % 256. 1064%256=40, the ascii value for "(". I hope this answers your question.

thanks. Yeah it does. I guess this is more of a language to use as a way of testing your brain. Rather than a way to write programmes then? Interesting.

@Fogmeister there are many esoteric programming languages that are more brain twisting exercises than useful for doing real work, although they CAN do real work if you try hard enough.

Cinnamon Gum, 7 bytes
0000000: 7043 dc95 6d4f ce                        pC..mO.

Try it online.
Would have been 6 bytes with the old p syntax :/
Explanation
Decompresses to p~=~(:)-, the p stage then simply reads input and repeats the = n times.

Can you link to language spec for this?

@RobertFraser I don't have a formal specification or any documentation currently, but you can check out the source at the GitHub repo: https://github.com/quartata/cinnamon-gum

Brian & Chuck, 31 bytes
,{-?>}-):(=?
#}<<.{?_<.<.<.<.<.

Input in the form of a byte value, so e.g. input ! gives a snake of length 33.
Try it online!
It's been a while...
Explanation
A quick Brian & Chuck primer:

The first line of the program is Brian, the second is Chuck.
Brian and Chuck are two Brainfuck-like instances. The main catch is that Chuck's program is Brian's tape and vice versa. The tape heads/instruction pointers start on the first cell of each tape and execution starts on Brian.
As for the commands, there are a few differences. Only Brian can use , (input) and only Chuck can use . (output). In addition to < and > there are { and } which move the tape head up to the next zero cell (or in the case of { to the left end of the tape if there is no zero cell on the way). Instead of [...], the only control flow is ? which switches control to the other instance if the current cell is non-zero. The first executed instruction on the other cell is the one after the condition. And finally, _ is just an alias for null-bytes, for convenience.

Now the code. Brian starts with this:
,{-?

This reads the input into Chuck's first cell, then moves the tape head to the left with { (does nothing right now) and decrements the input with - before switching control for Chuck if the value is still non-zero. This begins the main loop. Chuck then runs this bit:
}<<.{?

This moves the tape head on Brian to the very end, moves two cells left onto the = and prints it before the tape head all the way to the left and switching control back to Brian. This is how loops generally work in B&C.
Once the input has been reduced to zero, the ? on Brian's tape will do nothing. Then Brian executes this part:
>}-):(=?

The ):(= are no-ops, so the actual code is just >}-?. We move off the zero cell with >, move up to _ with }, decrement it to make it non-zero and switch to Chuck with ?. Then the last bit on Chuck is run:
<.<.<.<.<.

This simply prints the five characters in front of Chuck, i.e. =(:)-. Note that we need to print another = since the main loop is only executed N-1 times for input N.

Congrats on 100k

V, 8 bytes
Àé=A(:)-

Try it online!
V uses the "Latin1" encoding.
Explanation:
À        "Arg1 times:
 é=      "Insert an '='
   A(:)- "Append the head

I count 10 bytes

@zwei see my edit.

Got it! That's better.

Retina, 10 bytes
.+
$*=(:)-

Try it online!
This is a simple regex substitution.
It matches .+ which matches the whole input, and then substitutes it with $*=(;)-.
The $* is a feature unique in Retina: it is the character-repetition special operator.
For example, 5$*x would become xxxxx.
In the case that the previous argument is absent, the whole match is used as the default argument.

Python, 21 bytes
lambda n:"="*n+"(:)-"

Ideone it!

You can cut 3 bytes by doing: "="*input()+"(:)-"

@gowrath Then it won't be printing anything

It'll output it if you're in the interpreter no? Op said you can get output in any way.

@gowrath You can't assume that we're in REPL

Is that a general rule for code golfing? New here :)

@gowrath Usually.

Java 8, 52 bytes
n->new String(new char[n]).replace("\0","=")+"(:)-";

Test suite. (Compile > Execute)
Credits.
teh traditional way, 61 54 53 bytes
7 bytes thanks to Kevin Cruijssen.
1 byte thanks to Dom Hastings.
n->{String s="";for(;n-->0;)s+="=";return s+"(:)-";};

+1 Oh, and for the traditional one: for(int i=0;i<n;i++) can be golfed to for(;n>0;n--), since you don't need the input for anything else than the for-loop anyway.

@KevinCruijssen Thanks, edited

Testing via the link you provided it looks like you can change the for loop to: for(;n-->0;) to save another byte!

@DomHastings edited with thanks

Haskell, 25 bytes
f n=('='<$[1..n])++"(:)-"

'='<$[1..n] is equivalent to replicate n '='.

Jelly, 9 bytes
”=x;“(:)-

Try it online!
”=x;“(:)-
”=          '='
  x         repeat (argument) that many times
   ;        append
    “(:)-   "(:)-"

05AB1E, 10 9 bytes
'=×"ÿ(:)-

Explanation
'=         # push equal-sign
  ×        # repeat input nr of times
   "ÿ(:)-  # interpolate snake body with head as a string
           # implicitly display

Try it online
1 byte saved thanks to Adnan.

'=×"ÿ(:)- for 9 bytes :). This uses string interpolation.

@Adnan: Aaah, so that's what ÿ does :)

C, 38
f(n){for(;n--;printf(n?"=":"=(:)-"));}

Try it on ideone.

Not shorter, but cooler: f(n){~-printf(n?"=":"=(:)-")||f(~-n);}.

f(n){for(;n;printf(n--?"=":"(:)-"));} for -1.

@EʀɪᴋᴛʜᴇGᴏʟғᴇʀ - That doesn't output the head.

@owacoder Well, C is not my primary language...

@EʀɪᴋᴛʜᴇGᴏʟғᴇʀ And that's why you shouldn't post untested golfing suggestions (especially if it would have taken you 5 seconds to test your suggestion with the link provided in the answer).

C#,  28 bytes
n=>new string('=',n)+"(:)-";

im always interested by the lambda snippets. how can you even run this?

@downrep_nation it takes in an int and automatically returns the string because it is only one statement

The answer should be a full program or a function, not just a snippet. So this answer seems incomplete.

@raznagul This is an anonymous function therefore it is complete

@TheLethalCoder: Maybe try online link would help to understand it. (http://csharppad.com/)

Under Clarifications OP wrote "You may write a function instead of a regular program," so I think this is valid on that count. However, it does not actually print anything when invoked, and I'm not sure that's kosher since the requirements say "print a snake." (If it was n=>Console.Write(new string...); I believe that would be valid.)

@Jordan •You can get input and output in any acceptable way.. I take that to mean returning the string is valid output

@raznagul It is essentially a Func<int, string> just anonymous

Javascript, 23 bytes
n=>"=".repeat(n)+"(:)-"

I was just about to post exactly that code! Beat me to it! Have an upvote

Today I learned about arrow functions. Thank you. Didn't know that was a thing

How do you call that instance of the function? I just tried n(3) and received a Uncaught ReferenceError: n is not defined error...

@WallyWest - try x=n=>"=".repeat(n)+"(:)-"; x(7);

@eithedog Then shouldn't the answer have the initial x= and changed to 25 chars?

@WallyWest no, because the requirement is You may write a function instead of a regular program. x= is the assignment of the anonymous function

Python, 24 bytes.
print"="*input()+"(:)-"

input() gets input from user
*, when used on strings and an integer, creates a new string, which is made of joined copies of the original. For example: "hello "*3 outputs hello hello hello.
By multiplying = and input(), you get a string of = the length that the user specifies.
Using + joins two strings, in this case, our body "=…=" with our head, "(:)-" to make the snake.
print outputs the result.

GolfScript, 11 10 bytes
~"="*"(:)-"

Multiplies "=" by input, and adds head.
-1 thanks to Leaky Nun

Mathematica, 21 20 bytes
"="~Table~#<>"(:)-"&

Anonymous function. Takes a number n as input, and returns a snake of length n as output. "="~Table~# generates a list {"=", "=", ..., "="} of length n, and <>"(:)-" concatenates the list's elements and appends "(:)-" to the resulting string.

golfable by one more byte: "="~Table~#<>"(:)-"&

R, 32 27 bytes
This solution is pretty straightforward, rep function repeats the first element ("=") scan() times, which is in fact the user's input.

a=scan();cat(rep("=",a),"(:)-")

EDIT:
cat(rep("=",scan()),"(:)-")

Slighly shorter answer, using scan() directly.
Alternatively,
cat(rep("=",scan()),"(:)-",sep="")

for a non-chopped snake (34 bytes)

I would say the sep="" is needed here, otherwise your snake looks like the one that traversed the railway: = = = (:)-.

The snake produced here is indeed a bit minced, but OP's consigns only state that the length of the snake is the number of equal signs before the head. I will add the  sep as a side note nonetheless ;)

Batch, 68 bytes
@set h=(:)-
@for /l %%i in (1,1,%1)do @call set h==%%h%%
@echo %h%

C, 46 45 43 bytes
saved 2 bytes thanks to owacoder!
saved 3 bytes thanks to rici!
f(n){while(4-printf("=\0(:)-"+2*!n--));}

Try it on Ideone!

The mysterious --> operator strikes again.

@LeakyNun 46 bytes version was without the goes to operator, than I remembered the goes to operator ;)

You can remove the >0 and save two bytes.

Slightly shorter: f(n){while(4-printf("=\0(:)-"+2*!n--));}

CJam, 13 11 bytes
qi'=*"(:)-"

Test it here.
-2 bytes thanks to quartata

You can do '=* instead of {'=}*.

PowerShell v2+, 19 bytes
'='*$args[0]+'(:)-'

Full program. Takes input $args[0], uses string multiplication to construct the body, then string concatenation to tack on the head.
PS C:\Tools\Scripts\golfing> .\snakes-all-around.ps1 7
=======(:)-

PS C:\Tools\Scripts\golfing> .\snakes-all-around.ps1 77
=============================================================================(:)-

Kudos to you, I got as far as 26:
"$("="*[int]$args[0])(:)-"

JAISBaL, 9 bytes
t=*Qb(:)-

Verbose:
# \# enable verbose parsing #\
push1 =        \# push = onto the stack #\
mul            \# multiply the top two values of the stack #\
popout         \# pop the top value of a stack and print it #\
print4 (:)-    \# print (:)- #\

Tested with JAISBaL-0.0.7
(The compiled .jar was just pushed, but the source has been up on git for a while)

Use a # before the language name to make it look like everybody else's.

@MichaelKlein okay

Perl 6,  16 15  12 bytes
{"{'='x$_}(:)-"}
{'='x$_~'(:)-'}
'='x*~'(:)-'
Explanation:
'=' x * # ｢=｣ string repeated by the only parameter ｢*｣
~        # concatenated with
'(:)-'   # the head

Usage:
# store it in the lexical namespace
my &snake = '='x*~'(:)-';

put snake 10;

# put ^5 .map: &snake;
put ^5 .map: '='x*~'(:)-';

==========(:)-
(:)- =(:)- ==(:)- ===(:)- ====(:)- =====(:)-

Cheddar, 15 bytes (noncompeting)
n->'='*n+'(:)-'

A straightforward answer.

Sesos, 11 bytes
Hexdump:
0000000: aaaa5e a0f7b4 ed4cee 5d3b                         ..^....L.];

Try it online!
Assembler:
set numin
add 61
fwd 1
get
jmp,sub 1,rwd 1,put,fwd 1,jnz
add 40,put
rwd 1,sub 3,put
fwd 1,add 1,put
add 4,put

K, 17 Bytes
{,[x#"=";"(:)-"]}

Example;
f:{,[x#"=";"(:)-"]}
-1(f'!10);          /print out the result of calling f where x is 0 1 2 3 4 5....
(:)-
=(:)-
==(:)-
===(:)-
====(:)-
=====(:)-
======(:)-
=======(:)-
========(:)-
=========(:)-

Explanation;
{}                 /function x is implicit and is an int
x#"="              /take (#) x of "=" --> so 3#"=" gives "==="
,[x#"=";"(:)-"]    /comma is a join that takes 2 args --> ,[x;y] gives the concatination of x and y --> "a","abc" is the same as ,["a";"abc"] and gives "aabc"

What is -1(...);?

Save a byte: {(x#"="),"(:)-"}

Thanks Adam.
-1 Prints to the console.
-1"Hello"; will print Hello

But isn't printing implicit?

Yes but it includes the double quotes...
"====(:)-" rather than; =====(:)-

save 2 bytes with {|"-):(",x#"="}. Try it online!.

Perl, 16 + 1 (-p flag) = 17 bytes
$_="="x$_."(:)-"

Needs -p flag, so run with :
perl -pe '$_="="x$_."(:)-"'

Minkolang 0.15, 12 bytes
"=(:)-"nD$O.

Try it here!
Explanation
"=(:)-"         Push this to the stack in reverse order - ["-",")",":","(","="]
       n        Take number from input
        D       Pop k and duplicate top of stack (the "=") k times
         $O.    Output whole stack as characters and stop.

Befunge-98, 24 bytes
Takes numerical input from the user, then prints the snake.
'=&:00pk:00gk,"-):("4k,@

Brainfuck, 53 bytes
++++[->+++++<]>[->+++>++<<],>+<[->.<]>>.<---.>+.++++.

Explanation:
++++[->+++++<]    We build a 20 as 5*4
>[->+++>++<<]     We build a 60 and a 40 in two neighboring cells out of the 20, by multiplying the 20 with 3 and with 2
,>+<[->.<]        Read input, and print 61 ('=') as many times as the input idicates
>>.<---.>+.++++.  Print out the rest, "(:)-", noting how close each character is to either 60 or 40.

x86 COM, 29 bytes
8A 0E 82 00 80 E9 30 B4
02 B2 3D CD 21 49 75 FB
BA 18 01 B4 09 CD 21 C3
28 3A 29 2D 24

aka
16DA:0100 8A0E8200      MOV     CL,[0082]
16DA:0104 80E930        SUB     CL,30
16DA:0107 B402          MOV     AH,02
16DA:0109 B23D          MOV     DL,3D
16DA:010B CD21          INT     21
16DA:010D 49            DEC     CX
16DA:010E 75FB          JNZ     010B
16DA:0110 BA1801        MOV     DX,0118
16DA:0113 B409          MOV     AH,09
16DA:0115 CD21          INT     21
16DA:0117 C3            RET
16DA:0118 283A          SUB     [BP+SI],BH // Snake Head
16DA:011A 292D          SUB     [DI],BP    // Snake Head
16DA:011C 2400          AND     AL,00      // Snake Head

Name it "snake.com"
Call it from cmd (tested with Win XP), parameters 1 to 9 supported:
snake 5

results in
=====(:)-

C#, 42 bytes
string w(int n)=>new string('=',n)+"(:)-";

Try it here!

Does this code print the string?

@Jordan: No, this is a function that returns the string.

The requirements say solutions should "print a snake." I'm not sure if just returning a string is kosher.

Matlab / Octave, 22 bytes
@(n)[~(1:n)+61 '(:)-']

This is an anonymous function.
Try it on Ideone.
Explanation
Assume n= 5.
1:n produces the row vector [1 2 3 4 5].
~(1:n) negates each entry, so it gives [0 0 0 0 0].
...+61 adds 61 to each entry, so it gives [61 61 61 61 61]. 61 is the ASCII value of character =.
[... '(:)-'] concatenates that with the string '(:)-'. This automatically converts [61 61 61 61 61] into the string '=====' before the concatenation.

Dyalog APL, 13 bytes
'(:)-',⍨⍴∘'='

'(:)-',⍨ the snake head appended to
⍴∘'=' n repetitions of a body segment
TryAPL online!
A proper function. The equivalent program is '(:)-',⍨⎕⍴'='.

You forgot the byte count.

@m654 The snake nibbled it!

Lua, 28 Bytes
Takes input in the form of a command-line argument and outputs via its return value. Even if it uses a return statement, it is still a full program :).
return("="):rep(...).."(:)-"

LiveScript, 15 bytes
->'='*it+'(:)-'

BASIC, 30 bytes
Let's keep it simple in BASIC.  QB64 and TRS-80 Extended Color BASIC both tie, since TRS-80 needs a line number but doesn't need the space after INPUT, and it won't let you use INPUT in immediate mode.  One liners are rare on a 32x16 screen.
TRS-80: (should also work on Microsoft GW-BASIC/BASICA)
0INPUTL:?STRING$(L,"=");"(:)-"

QB64:
INPUT L:?STRING$(L,"=");"(:)-"

GW-BASIC seems to require a space after INPUT.

My old Model 1 Level 1 could use abbreviations like "I." for "INPUT" but I don't think Level 1 BASIC had STRING$.

Java 1.7, 46 bytes
A recursive (and shorter) alternative to the iterative and 'replace' versions.
String f(int n){return n>0?"="+f(--n):"(:)-";}

Run it here.
This function first builds the n tail elements recursively, then appends the head.

Brainfuck, 47 46 44 bytes
+[+<-[<]>->>++]<<++<,[->.<]<.>>---.<<+.++++.

Try it online! Takes input as a single byte value (e.g. space is 32). The program requires an interpreter with 8-bit cells and a tape not bounded on the left.
+[+<-[<]>->>++] (found by a bit of brute forcing) initialises the tape to
[253, 0, 0, 232, 0, 0, 40, 0, 59, 86, 0]
                                      ^

We then increment the 59 to 61 with <<++ and read the input char with <,. [->.<] then outputs the required number of =, and <.>>---.<<+.++++. outputs the (:)- portion, making use of the aforementioned 61 as well as the 40 two cells away.

Fish (><>), 33 bytes:
An upside down F cause ><>. Takes integer as command line argument by running
./fish.py snake.fish -v [number].
\
"
-
)
:
(!;!?lo<
=
"
>{1-:?!^}:

Try it here! The best explanation is to watch it with animation on the website.

Turing machine code, 242 bytes
0 * * r 0
0 _ _ l A
A 0 9 l A
A 1 0 r 1
A 2 1 r 1
A 3 2 r 1
A 4 3 r 1
A 5 4 r 1
A 6 5 r 1
A 7 6 r 1
A 8 7 r 1
A 9 8 r 1
A _ _ r 3
1 _ = l 2
1 * * r 1
2 = = l 2
2 * * * A
3 = = r 4
3 * _ r 3
4 = = r 4
4 _ ( r 6
6 _ : r 7
7 _ ) r 8
8 _ - * halt

Try it online.

Befunge 93, 25 bytes
Try it Online!
1+:&`#v_"=",
"(:)-"<@,,,,

Not compatible with '98, because the & character acts like r when there is no input, instead of repeating the last token

C++14, 59 bytes
As unnamed lambda:
#import<string>
[](int n){return std::string(n,61)+"(:)-";}

Usage:
#include<iostream>

#import<string>
auto f=
  [](int n){return std::string(n,61)+"(:)-";}
;

int main(){
  std::cout << f(2) << std::endl;
  std::cout << f(5) << std::endl;
  std::cout << f(10) << std::endl;
}

Common Lisp, 29 bytes
(format t"~v{=~}(:)-"(read)1)

Befunge-98 (FBBI), 22 18 bytes
Saved 4 bytes by putting the "-):(" at the beginning. This let me get rid of the separate printing of the head, and also the ' for pushing the =.
"-):(="&k:$$>:#,_@

Try it online!
Explanation
"-):(="                   Pushes '-):(=' to the stack - the head reversed
       &k:                Duplicates the = N+1 times (now there are N+2 '='s on the stack)
          $$              Discards 2 so that there are N '='s
            >:#,_         Prints all the top non-zero chars on the stack (the whole snake)
                 @        Exits

VBA Excel, 23 bytes
using Immediate window and cell [A1] as input
?string([A1],"=")"(:)-"

Vyxal, 11 9 bytes
\=*\:øb‹+

Try it Online!

Try it Online! for 9 bytes

Pyth, 10 bytes
+*\=Q"(:)-

Test suite.
+*\=Q"(:)-
    Q        get input
 *\=         repeat "=" that many times
+    "(:)-   append "(:)-"

C++, 106 103 bytes
#include <iostream>
void s(int n){for(int i=0;i<n;i++){std::cout<<"=";}std::cout<<"(:)-"<<std::endl;}

Usage
#include <string>
int main(int argc, char *argv[]) {
    int length = std::stoi(argv[1]);
    s(length);
    return 0;
}

Ungolfed
#include <iostream> // for printing
void outputSnake(int length) {
    for (int i = 0; i < length; i++) { // iterates over length of snake
        std::cout << "="; // prints an equals sign
    }
    std::cout << "(:)-" << std::endl; // prints rest of snake
}

Thanks @LeakyNun for shaving off 3 bytes.

Replace i!=n+1 with i<n, and I am not sure if std:: is needed.

@LeakyNun I would have to add "using namespace std;" to remove the std portion, but i'll replace that not equal sign

Couldn't you replace the for-loop with ´while(n-->0)´?

><>, 26 23 bytes
:?!v"="o1-
oo;>"-):("oo

-3 bytes thanks to Leaky Nun
Test it here. (you have to input the code manually)

Java, 133 bytes
public class Snake {
    public void s(int n){
        for(int i=0;i<n;i++){
            System.out.print("=");
        }
        System.out.println("(:)-");
    }
}

This site says that your code is 165 bytes.

If you prefer to just share the method then don't include the class at all, otherwise provide a main in order to provide a complete program. Anyway, class don't need to be public. Class name could be shorter. Also, you could save some bytes by concatenating the "=" and printing them all at the end.Don't include {} or unnecessary spaces. Here are these suggestions: http://pastebin.com/8jLNL65V

@daHugLenny I used wc -c on GNU/Linux to count the bytes.

Assuming tabs (because SE sites convert them to spaces) the count actually turns out to 132 bytes. (And sorry @Master_ex, it seems like LeakyNun has already used what you said in their answer so it can't be used here.)

@ValueInk, if you referring to LeakyNun's java answer (the traditional one) it seems that it was posted after my comment and in my pastebin link I save some more bytes in the for loop, but no problem, I just wanted to help :-)

Bash, 52 36 bytes

while [[ ${#a} -lt $1 ]];do a=$a=;done;echo "$a(:)~"

printf -vs %$1s;echo "${s// /=}(:)~"

Excellent suggestion by @manatwork.
If one would like to use external programs (sed) this could be a bit smaller(31 bytes):
printf "%$1s(:)~"|sed 's/ /=/g'

Run like that:
$ bash snake.sh 1
=(:)~
$ bash snake.sh 3
===(:)~

I would go without while: printf -vs %$1s;echo "${s// /=}(:)~".

Javascript (using external library) (39 bytes)
n=>_.Range(0,n).Write("=",x=>"")+"(:)-"

Link to lib: https://github.com/mvegh1/Enumerable
Code explanation: Create an array of n elements, and Write a concatenated string with "=" as the delimiter and an empty string as the current element. Then concatenate the head of the snake

Brainfuck, 67 bytes
Code:
>++++++[>++++++++++<-]>+<,[->.<]<++++[>++++++++++<-]>.>---.<+.++++.

Explanation:
> At #1
++++++[>++++++++++<-]>+< Put '=' in #2
, Input into #1
[->.<] Output '=' #1 times thereby emptying #1
<++++[>++++++++++<-]>. Put '(' in #1 and output

> At #2
--- Change #2 to ':'
. Output

< At #1
+.++++. Change to '(' and 'minus' and output

Try it online!
Input works using the corresponding ASCII characters - that is, to input 33 you would type !. For convenience, you can use \d as the input in the interpreter linked, where d is any non-negative integer.

Julia, 15 bytes
x->"="^x*"(:)-"

Wow, this is short.

Racket, 46 bytes
(λ(n)(string-append(make-string n#\=)"(:)-"))

Pretty terrible golfing language :)))

, 10 chars / 13 bytes
⍘=Ċï+'(:)-

Try it here (ES6 browsers only).
Should be rather self-explanatory.

Silicon, 12 bytes
I"="*"(:)-"+

Explanation:
I"="*"(:)-"+

    *   Times
I       Get an integer as input
"="     Push "="

"(:)-"  Push "(:)-"
+       Append

Alternatively, 11 bytes:
"="ã"(:)-"+

PHP, 27 bytes
Not the most wonderfull creation, but with register_globals on you can set it via url.
<?=str_repeat('=',$n)?>(:)-

Ruby, 20 bytes
->n{puts?=*n+"(:)-"}

Ruby, 27 bytes
puts"="*($*[0].to_i)+"(:)-"

No need for the parenthesis.

Matricks, 24 bytes
Very simple, just wanted to show off the new matrix definition feature.
m61:1:n;;a<40,58,41,45>;

Run with python matricks.py snek.txt [[]] <input> --asciiprint

MATL, 12 bytes
61iY"'(:)-'h

Try it on MATL Online.
Explanation
61       % ASCII value for '='
i        % Take input number, n
Y"       % Row vector with 61 repeated n times
'(:)-'   % Push this string
h        % Concatenate horizontally. This converts to string. Implicitly display

Nim, 46 bytes
import strutils,future
n=>repeat("=",n)&"(:)-"

This is an anonymous function that must be passed to a procedure to be used. To test, use the testing program below:
import strutils,future
proc test(f: int -> string) = echo f(#[Your input here]#)
test(n=>repeat("=",n)&"(:)-")

Clojure, 35 bytes
#(str(apply str(repeat %\=))"(:)-")

This is an anonymous/unnamed function that takes a single integer as an argument and returns a string.

ECMAScript 6, 37 44 37 bytes
Try it here!
Golfed
alert("=".repeat(prompt())+"(:)-");

Ungolfed
alert("=".repeat(prompt()) + "(:)-");

Revisions

Original revision.
Added alert(); because it used to save to a variable, n. Try it here!
Used ECMAScript 6's String.prototype.repeat method instead of the previous method that didn't even work and took more bytes. Try it here!

ECMAScript 6, 53 bytes
This is a version of the above code that is a function, not a full program. Try it here!
Golfed
function makeSnakeArt(n){return"=".repeat(n)+"(:)-")}

Ungolfed
function makeSnakeArt(n) {
    return "=".repeat(n) + "(:)-"
}

alert(makeSnakeArt(5));

Revisions

Original revision, stemming off the 3rd revision of the full program. Try it here!
Returns the snake instead of alerting it. Try it here!

@WallyWest I'll add that into the answer.

@WallyWest Why'd you delete your comment?

PL/SQL: 28 bytes
rpad('=','&n','=')||'(:)-');

Tried it? There is no change to work due to the extra ). 2) No idea about the dialect, but wouldn't lpad('(:)~',&n+4,'='); work? 3) This is just a snippet, not a valid solution.

VBA, 37 bytes
Function S(L):S=String(L,"=")&"(:)-"

and enter gives the End Function. Immediate window of VBA editor:
?S(41)
=========================================(:)-

J, 14 bytes
'(:)-',~'='#~]

Very simple. This is a five train:
'(:)-' ,~ '=' #~ ]

Both strings, in this case, become constant verbs. #~ essentially repeats its left argument the amount of times as its right argument. ,~ then appends its left argument to the end of its right argument.
Test cases:
   f 2
==(:)-
   f 7
=======(:)-
   f 10
==========(:)-
   f 0
(:)-

I think that it would look more snake-like with a tilde at the end, but eh.

Kotlin, 34 bytes
{String(ByteArray(it){61})+"(:)-"}

This assumes that a function of (Int)->String type is requested (in such case, it is assumed to be an Int). Version with explicit typing (40 bytes):
{n:Int->String(ByteArray(n){61})+"(:)-"}

Try it out on the JVM target:
fun main(args: Array<String>) {
    val f: (Int)->String = {String(ByteArray(it){61})+"(:)-"}
    println(f(5))
}

R, 39 bytes
Mildly different than others above
for(i in 1:scan())cat("=");cat("(:)-")

or, if we can precede the line with the input
->n;for(i in 1:n)cat("=");cat("(:)-")

Perl, 16 bytes
say'='x<>.'(:)-'

Takes input from stdin

Pyke, 10 bytes
\=*"(:)-"+

Try it here!
Or 8 bytes (noncompeting)
\=*"(:)-

Try it here!

Python, 23 bytes
print'='*input()+'(:)-'

Unless it's Python 3, you can remove the int() part.

@daHugLenny thanks, -5 bytes

Ruby, 24 bytes
def f(l) ?=*l+"(:)-";end

PyMin, 15 bytes
»"="*¬+"(:)-"

GameMaker Language, 49 bytes
s="(:)-"for(a=0;a<argument0;a++){s="="+s}return s

Factor 34
[ [ "="write ] times "(:>~"print ]

Quotation (anonymous function) that takes a number and prints a snake.
Alternative (also 34):
[ 61 <string> ":>~""("glue print ]

Sorry, but i made some aesthetic changes...
10 [ [ "="write ] times "(:>~"print ] call
==========(:>~

Neoscript, 15 bytes
{n|'=*n+"(:)-"}

Fourier, 28 bytes
I(61ai^~i)40a-8a58a32a41a+4a

Try it online

GNU sed, 16 bytes
y/0/=/;s/$/(:)-/

Since sed has no native support for numbers, the input is given in unary based on this consensus.
Run:
sed -f snake.sed <<< "000"

Output:
===(:)-

Scala, 30 Bytes
(x:Int)=>print(("="*x)+"(:)-")

Microscript, 14 bytes
ic'=P]"-):("ah

Microscript II, 13 bytes
"="sN*p"(:)-"

SNOBOL4 (CSNOBOL4), 39 bytes
 OUTPUT =LPAD('(:)-',INPUT + 4,'=')
END

Try it online!

Charcoal, 7 bytes
×=Ｎ(:)-

Try it online!
This is equivalent to the following code:
Print(Times("=", InputNumber()));
Print("(:)-");

Excel VBA, 20 Bytes
Anonymous VBE immediate window function that takes input, a, from range [A1] and outputs a snake of the length a to the VBE immediate window.
?[Rept("=",A1)]"(:)-

Sinclair ZX80 (4K ROM) ~39 bytes
 1 INPUT L
 2 FOR I=1 TO L
 3 PRINT "=";
 4 NEXT I
 5 PRINT "(:)-"

No explanation needed really.

JavaScript 6, input unary '=', 11B
x=>x+'(:)-'

Standard rule allowes it.
Fix it if that's not what you want.

Meta seems to say for such language unary is not allowed but also say allowed. Not sure which

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/


text:
I misspelled my domayn name
According to Alexa rankings, the top 10 websites are:
google.com
youtube.com
facebook.com
baidu.com
yahoo.com
wikipedia.org
amazon.com
twitter.com
qq.com
google.co.in

Being the top 10 visited websites, these are probably also the top 10 misspelled websites [Citation Needed].
Your task
Your goal is to write a program or function that accepts a string containing a misspelled domain name, and outputs all domain names on the top 10 list that are spelled similarly.
Rules

Each input may be up to three characters off from a correct website. A changed character may a substitution (cat -> cot), addition (cat -> cant), or removal (cat -> at).
Moving a letter counts as two characters changed (the deletion of one character and the addition of another)
The input will only include the characters a-z, period, and dash
The name of a website does not include the http(s):// or the www. The websites are exactly as listed above.
The program must print out all websites that match the input.
Case doesn't matter. The test cases will be presented as lower case, but if your program requires upper case, that's fine too.
As always, no standard loopholes.
This is code-golf, so shortest answer in bytes wins!

Some test cases
(Input followed by outputs)
yahoo.com
yahoo.com (no change for correct spelling)

goggle.com
google.com

wikipedia.organ
wikipedia.org

bidua.cm
baidu.com

.om
qq.com

google.co.i
google.com and google.co.in

google.com
google.com and google.co.in

twipper.com
twitter.com

yahoo.org
yahoo.com

amazing.com
amazon.com

factbook.co
facebook.com

ki-pedia.org
wikipedia.org

google.co.india
google.co.in

goo.com
google.com

aol.com
qq.com

qqzon.com
qq.com and amazon.com

Leaderboards
Here is a Stack Snippet to generate both a regular leaderboard and an overview of winners by language.
To make sure that your answer shows up, please start your answer with a headline, using the following Markdown template:
# Language Name, N bytes

where N is the size of your submission. If you improve your score, you can keep old scores in the headline, by striking them through. For instance:
# Ruby, <s>104</s> <s>101</s> 96 bytes

If there you want to include multiple numbers in your header (e.g. because your score is the sum of two files or you want to list interpreter flag penalties separately), make sure that the actual score is the last number in the header:
# Perl, 43 + 2 (-p flag) = 45 bytes

You can also make the language name a link which will then show up in the leaderboard snippet:
# [><>](http://esolangs.org/wiki/Fish), 121 bytes

var QUESTION_ID=87174,OVERRIDE_USER=41505;function answersUrl(e){return"https://api.stackexchange.com/2.2/questions/"+QUESTION_ID+"/answers?page="+e+"&pagesize=100&order=desc&sort=creation&site=codegolf&filter="+ANSWER_FILTER}function commentUrl(e,s){return"https://api.stackexchange.com/2.2/answers/"+s.join(";")+"/comments?page="+e+"&pagesize=100&order=desc&sort=creation&site=codegolf&filter="+COMMENT_FILTER}function getAnswers(){jQuery.ajax({url:answersUrl(answer_page++),method:"get",dataType:"jsonp",crossDomain:!0,success:function(e){answers.push.apply(answers,e.items),answers_hash=[],answer_ids=[],e.items.forEach(function(e){e.comments=[];var s=+e.share_link.match(/\d+/);answer_ids.push(s),answers_hash[s]=e}),e.has_more||(more_answers=!1),comment_page=1,getComments()}})}function getComments(){jQuery.ajax({url:commentUrl(comment_page++,answer_ids),method:"get",dataType:"jsonp",crossDomain:!0,success:function(e){e.items.forEach(function(e){e.owner.user_id===OVERRIDE_USER&&answers_hash[e.post_id].comments.push(e)}),e.has_more?getComments():more_answers?getAnswers():process()}})}function getAuthorName(e){return e.owner.display_name}function process(){var e=[];answers.forEach(function(s){var r=s.body;s.comments.forEach(function(e){OVERRIDE_REG.test(e.body)&&(r="
"+e.body.replace(OVERRIDE_REG,"")+"
")});var a=r.match(SCORE_REG);a&&e.push({user:getAuthorName(s),size:+a[2],language:a[1],link:s.share_link})}),e.sort(function(e,s){var r=e.size,a=s.size;return r-a});var s={},r=1,a=null,n=1;e.forEach(function(e){e.size!=a&&(n=r),a=e.size,++r;var t=jQuery("#answer-template").html();t=t.replace("{{PLACE}}",n+".").replace("{{NAME}}",e.user).replace("{{LANGUAGE}}",e.language).replace("{{SIZE}}",e.size).replace("{{LINK}}",e.link),t=jQuery(t),jQuery("#answers").append(t);var o=e.language;/s.lang?1:e.lang<s.lang?-1:0});for(var c=0;c<t.length;++c){var i=jQuery("#language-template").html(),o=t[c];i=i.replace("{{LANGUAGE}}",o.lang).replace("{{NAME}}",o.user).replace("{{SIZE}}",o.size).replace("{{LINK}}",o.link),i=jQuery(i),jQuery("#languages").append(i)}}var ANSWER_FILTER="!t)IWYnsLAZle2tQ3KqrVveCRJfxcRLe",COMMENT_FILTER="!)Q2B_A2kjfAiU78X(md6BoYk",answers=[],answers_hash,answer_ids,answer_page=1,more_answers=!0,comment_page;getAnswers();var SCORE_REG=/<h\d>\s*([^\n,]*[^\s,]),.*?(\d+)(?=[^\n\d<>]*(?:<(?:s>[^\n<>]*<\/s>|[^\n<>]+>)[^\n\d<>]*)*<\/h\d>)/,OVERRIDE_REG=/^Override\s*header:\s*/i;
body{text-align:left!important}#answer-list,#language-list{padding:10px;width:290px;float:left}table thead{font-weight:700}table td{padding:5px}
 <link rel="stylesheet" type="text/css" href="//cdn.sstatic.net/codegolf/all.css?v=83c949450c8b">

Leaderboard

	Author	Language	Size

Winners by Language

Language	User	Score

{{PLACE}}	{{NAME}}	{{LANGUAGE}}	{{SIZE}}	Link

{{LANGUAGE}}	{{NAME}}	{{SIZE}}	Link

I think "outputs the correct version" would be clearer if it said that every possible correct version must be output, as the rules later say.

@xnor How's this? I also added some corner cases to the test suite.

Looks good. Are the inputs limited to printable ASCII? In particular, can there be spaces or newlines?

@xnor Good point; I'll clarify that

@xnor The input will only include the characters a-z, period, and dash

Borderline dupe of Levenshtein distance, since it's basically just using that as a filter predicate.

Mathematica, 167 166 bytes
Saved one byte thanks to Martin Ender
iSelect[{"google.com","youtube.com","facebook.com","baidu.com","yahoo.com","wikipedia.org","amazon.com","twitter.com","qq.com","google.co.in"},#~EditDistance~i<4&]

Defines a pure function that returns a list of urls.
The  is this
This answer uses the same method as my NodeJS answer.

Nim, 229 205 185 174 bytes
import strutils,sequtils,future
s=>"googlexyoutubexfacebookxbaiduxyahooxwikipedia.org amazonxtwitterxqqxgoogle.co.in".replace("x",".com ").split.filterIt it.editDistance(s)<4

Yep, Nim has a builtin for Levenshtein distance (although it requires an import), which is what the question described.
Defines an anonymous procedure, which must be passed to a testing procedure to be used. An testing program is provided below:
import strutils,sequtils,future
proc test(d: string -> seq[string]) = echo d #[Your input here]#
test(s=>"googlexyoutubexfacebookxbaiduxyahooxwikipedia.org amazonxtwitterxqqxgoogle.co.in".replace("x",".com ").split.filterIt it.editDistance(s)<4)

Woah, I haven't seen Nim in the wild in a while. That's awesome that it's still an active language.

@MorganThrapp I just discovered it. It's a good language for golfing (if you can use a lambda), what with the builtins and the number of ways to call a proc.

Nice! I played around with it a bit last year and really liked it, I never did any golfing with it though.

JavaScript (ES6), 240 bytes

f=
s=>`google.com,youtube.com,facebook.com,baidu.com,yahoo.com,wikipedia.org,amazon.com,twitter.com,qq.com,google.co.in`.split`,`.filter(t=>[...s].map((u,i)=>(q=p=i+1,w=w.map((v,j)=>p=Math.min(++p,q-(u==t[j]),q=++v))),w=[...[...t].keys()])|p<4)
;
<input oninput=o.textContent=f(this.value).join`\n`>

Python, 216 200 193 183 bytes
import editdistance as e
i=raw_input()
print[n for n in"googlexyoutubexfacebookxbaiduxyahooxamazonxtwitterxqqxgoogle.co.in wikipedia.org".replace('x','.com ').split()if e.eval(i,n)<4]

The module editdistance calculates the Levenshtein distance, which is the straightforward implementation of what the challenge was asking for.
EDIT: Saved 3 bytes thanks to @shooqie
EDIT 2: Saved another 10 bytes thanks to @shooqie and @Frank

split() (without the space character) does the same thing (at least in Python 3)

@shooqie Yup, that works, thanks. Moving the list inside of the print statement instead of declaring a variable saves a few bytes too.

You could save a few characters by writing "import editdistance as e" and then calling e.eval rather than writing editdistance again.

You can remove the space between in and "googlexyoutube..." and split() and if (again, it works in Python 3). Also, in Python 2 you can omit parentheses when calling print

One last thing: print [...] -> print[...] and I noticed you're only using i in one place, why not e.eval(raw_input(),n)<4 then? Also, consider using input() instead of raw_input() since you only need a str.

@shooqie Huh. Completely missed that space after print. But for the other 2 things: input() in python 2 is the equivalent of eval(input()) in python 3, which causes an error, since the input contains a period, so python tries to evaluate it as a function from a class. Also, you can't put the raw_input() inside of the print statement, due to the fact that the output is generated using list comprehension.

Oh yeah. I guess it makes sense, forgot about it. Anyway, looks like this can't be golfed down any further :)

NodeJS, 163 161 151 bytes
10 bytes saved thanks to Copper's Nim solution
x=>"google youtube facebook baidu yahoo wikipedia.org,amazon twitter qq google.co.in".replace(/ /g,".com,").split`,`.filter(y=>require("leven")(x,y)<4)

Try it on Tonic
Defines an anonymous function that returns an array of urls.
This solution uses Levenshtein distance, which happens to be exactly what was described by the rules. This answer just selects the urls from an array based on if their Levenshtein distance is small enough.


text:
Determine the position of a non-negative number in the infinite spiral
Definition
The infinite spiral used in this question has 0 on the position (0,0), and continues like this:
16-15-14-13-12
 |           |
17  4--3--2 11
 |  |     |  |
18  5  0--1 10
 |  |        |
19  6--7--8--9
 |
20--21...

It is to be interpreted as a Cartesian plane.
For example, 1 is on the position (1,0), and 2 is on the position (1,1).
Task
Given a non-negative integer, output its position in the spiral.
Specs

Your spiral can start with 1 instead of 0. If it starts with 1, please indicate so in your answer.
Output the two numbers in any sensible format.

Testcases
The testcases are 0-indexed but you can use 1-indexed as well.
input output
0     (0,0)
1     (1,0)
2     (1,1)
3     (0,1)
4     (-1,1)
5     (-1,0)
6     (-1,-1)
7     (0,-1)
8     (1,-1)
9     (2,-1)
100   (-5,5)

Some bigger testcases would be nice.

@orlp Done.  –  –

Can we print coordinates as a complex number?

@orlp As long as it matches the regex.

I'm not sure how to interpret the regex requirement for return values. In some languages, the output of, e.g., a complex number, will depend on what function is called to print it.

Related.

Python, 46 bytes
f=lambda n:n and 1j**int((4*n-3)**.5-1)+f(n-1)

Dennis's answer suggested the idea of summing a list of complex numbers representing the unit steps. The question is how to find the number of quarter turns taken by step i.
[0, 1, 2, 2, 3, 3, 4, 4, 4, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7]

These are generated by int((4*k-n)**.5-1), and then converted to a direction unit vector via the complex exponent 1j**_.

Just keep this answer since you two came up with it independently...

Doubly awkward... I independently discovered it. But I guess your chat message was first, so no way to prove it.

Python, 53 bytes
lambda n:sum(1j**int((4*i+1)**.5-1)for i in range(n))

Just keep this answer since you two came up with it independently...

Jelly, 22 16 10 bytes
Ḷ×4‘Æ½’ı*S

This uses the quarter-turn approach from @xnor's/@orlp's answer.
Indexing is 0-based, output is a complex number. Try it online! or verify all test cases.
How it works
Ḷ×4‘Æ½’ı*S  Main link. Argument: n (integer)

Ḷ           Unlength; create the range [0, ..., n - 1].
 ×4         Multiply all integers in the range by 4.
   ‘        Increment the results.
    Æ½      Take the integer square root of each resulting integer.
      ’     Decrement the roots.
       ı*   Elevate the imaginary unit to the resulting powers.
         S  Add the results.

At which point will you rename Jelly to 'random noise'?

Right after all other esolangs do the same. It's only noise if you don't understand it.

@orlp But Jelly is the one that looks the most like semi-random (emphasis on AltGr and punctuation modifier keys) hammering of a US International keyboard...

Python 2, 72 62 bytes
n=2;x=[]
exec'x+=n/2*[1j**n];n+=1;'*input()
print-sum(x[:n-2])

Thanks to @xnor for suggesting and implementing the quarter-turn idea, which saved 10 bytes.
Indexing is 0-based, output is a complex number. Test it on Ideone.

Ruby, 57 55 bytes
This is a simple implementation based on Dennis's Python answer. Thanks to Doorknob for his help in debugging this answer. Golfing suggestions welcome.
->t{(1...t).flat_map{|n|[1i**n]*(n/2)}[0,t].reduce(:+)}

Ungolfed:
def spiral(t)
  x = []
  (1...t).each do |n|
    x+=[1i**n]*(n/2)
  end
  return x[0,t].reduce(:t)
end

Do you need the second pair of parentheses?

@LeakyNun Over n/2. I think so. Otherwise it tries to divide the array by 2 instead of multiplying by n/2. I'll see what I can do about it.

I don't think you need flat_map when regular map works just as well on ranges. Also, [0,t] gets you the same entries from an array as [0...t]

See here for the discussion about flat_map http://chat.stackexchange.com/transcript/message/31403761#31403761. Thanks for the [0,t] tip.

JavaScript (ES7), 75 bytes
n=>[0,0].map(_=>((a+2>>2)-a%2*n)*(a--&2?1:-1),a=(n*4+1)**.5|0,n-=a*a>>2)

Who needs complex arithmetic? Note: returns -0 instead of 0 in some cases.

Batch, 135 bytes
@set/an=%1,x=y=f=l=d=0,e=-1
:l
@set/ac=-e,e=d,d=c,n-=l+=f^^=1,x+=d*l,y+=e*l
@if %n% gtr 0 goto l
@set/ax+=d*n,y+=e*n
@echo %x%,%y%

Explanation: Follows the spiral out from the centre. Each pass through the loop rotates the current direction d,e by 90° anticlockwise, then the length of the arm l is incremented on alternate passes via the flag f and the next corner is calculated in x,y, until we overshoot the total length n, at which point we backtrack and print the resulting co-ordinates.


text:
How Many Rectangles in the Grid?

Well, although this challenge turned out to be a huge success, it also turned out to be very trivial to solve. Therefore, for those of looking for more of a challenge, I created a sequel to this challenge in which you must now count the number of unique rectangles. Check it out!
Now, for those of you looking to solve this challenge, here it comes.

Well, we don't really have a challenge like this yet, so here we go.
Consider this 3 x 3 grid of rectangles:

How many rectangles are there? Well, counting visually, we can see that there are actually 36 rectangles, including the entire plane itself, which are all shown in the animated GIF below:

The Task
The counting of rectangles as shown above is the task. In other words, given 2 integers greater than or equal to 0, m and n, where m represents the width and n represents the height, output the total number of rectangles in that m x n grid of rectangles.
Rules

The use of any built-ins that directly solve this problem is explicitly disallowed.

This challenge is not about finding the shortest answer, but finding the shortest answer in every language. Therefore, no answer will be accepted.

Standard loopholes are prohibited.

Test Cases
Presented in the format Array of Integers Input -> Integer Output:
[0,0] -> 0
[1,1] -> 1
[3,3] -> 36 (Visualized above)
[4,4] -> 100
[6,7] -> 588

References

http://oeis.org/A096948

Remember, this is code-golf, so shortest code wins!

I calculated 588 for the last test-case.

@LeakyNun Well then, I guess I missed some while counting them. It's fixed.

What is the maximum value of the input?

Relevant

Python, 22 bytes
lambda m,n:m*~m*n*~n/4

The formula m*n*(m+1)*(n+1)/4 is shortened using the bit-complement ~m=-(m+1), expressing (m+1)*(n+1) as ~m*~n.
Why is the number of rectangles m*n*(m+1)*(n+1)/4? Each rectangle is specified by the choice of two horizontal lines (top and bottom) and two vertical lines (left and right). There are m+1 horizontal lines, of which we choose a subset of two distinct ones. So the number of choices is choose(m+1,2), which is m*(m+1)/2. Multiplying by the n*(n+1)/2 choices for vertical lines gives the result.

That +1 trick is brilliant.

Jelly, 4 bytes
RS€P

Try it online!
Alternatively, also 4 bytes
pP€S

Try it online!

Good job. Thumbs up. :)

Care to explain?

There's also ×‘HP and ‘c2P and maybe other 4 byte alternatives.

@Pureferret This uses the formula from OEIS about this being the product of the nth and mth triangular number. R converts each number into the 1 based index: [1, 2, ..., n]. S is sum and € means 'each' so each list is summed, giving a list like: [nth triangle number, mth triangle number]. Then P takes the product of that list, which gives the desired result.

@FryAmTheEggman so what your saying is.... Magic

Mathematica, 15 bytes
##(1##+##+1)/4&

This is an unnamed function taking two integer arguments and returning the number of rectangles.
Explanation
The implementation is basically a very golfy form of the product of the two triangular numbers. It might be worth reading the section "Sequences of arguments" in this post for the details, but I'll try to summarise the gist here.
## expands to a sequence of all arguments. This is similar to splatting in other languages. For instance, if the arguments are 3 and 4, then {1, 2, ##, 5} will give you {1, 2, 3, 4, 5}. But this doesn't just work in lists, but in any expression whatsoever, e.g. f[1, 2, ##, 5] would also be f[1, 2, 3, 4, 5].
This gets interesting when you combine ## with operators. All operators in Mathematica are just short-hands for some f[...]-like expression (possibly nested). E.g. a+b is Plus[a, b] and a-b actually represents Plus[a, Times[-1, b]]. Now when you combine ## with operators, what Mathematica does is to expand the operators first, treating ## like a single operand, and expand them only at the end. By inserting ## in the right places, we can therefore use it both to multiply and to add the operands.
Let's do this for the code above:
##(1##+##+1)/4

Expanding it to its full form, we get this:
Times[##, Plus[Times[1, ##], ##, 1], Rational[1/4]]

Let's insert the function arguments a and b:
Times[a, b, Plus[Times[1, a, b], a, b, 1], Rational[1/4]]

And now we convert it back into standard mathematical notation:
a * b * (a * b + a + b + 1) / 4

A little rearranging shows that this is the product of the triangular numbers:
a * b * (a + 1) * (b + 1) / 4
(a * (a + 1) / 2) * (b * (b + 1) / 2)
T(a) * T(b)

Fun fact: this implementation is so golfy, it's the same length as the built-in for computing a single triangular number, PolygonalNumber.

Javascript (ES6), 17 bytes
m=>n=>m*n*~m*~n/4

A fork of this answer.

f=m=>n=>m*n*~m*~n/4
alert(f(prompt())(prompt()))

I'm not sure, is currying OK in languages that don't do this by default?

@JanDvorak Meta post.

C, 25 bytes
#define r(x,y)x*y*~x*~y/4

Purist version (27):
r(x,y){return x*y*~x*~y/4;}

ISO-er version (35):
#define r(x,y)((x)*(y)*~(x)*~(y)/4)

Which version do you think is best?

Jellyfish, 16 bytes
p|%/**+1
  4  Ei

Input format is [x y], output is just the result.
Try it online!
Alternative solution, same byte count:
pm%/*[*i
  4  +1

Explanation
Time to give Jellyfish the introduction it deserves! :)
Jellyfish is Zgarb's language based on his 2D syntax challenge. The semantics are largely inspired by J, but the syntax is a work of art. All functions are single characters and laid out on a grid. Functions take their arguments from the next token south and east of them and return the result north and west. This let's you create an interesting web of function calls where you reuse values by passing them into several functions from multiple directions.
If we ignore the fact that some of tokens in the above program are special operators (higher-level functions), the above program would be written something like this in a sane language:
p(|( /*(i*(i+1)) % 4 ))

Let's go through the code bottom-up. Input gets fed in by the i, which therefore evaluates to [x y].
The + on top of it receives this input together with the literal 1 and therefore increments both elements to give [(x+1) (y+1)] (most operations are threaded automatically over lists).
The other value of i is sent left, but the E splits is eastern argument north and west. That means the inputs to the right * are actually [x y] and [(x+1) (y+1)] so this computes [x*(x+1) y*(y+1)].
The next * up is actually modified by the preceding / which turns it into a fold operation. Folding * over a pair simply multiplies it, so that we get x*(x+1)*y*(y+1).
Now % is just division so it computes x*(x+1)*y*(y+1)/4. Unfortunately, this results in a float so we need to round it with the unary |. Finally, this value is fed to p which prints the final result.

I could've sworn I read something in the docs about integer division...

R, 40 35 bytes
Well, time to jump in at the deep end ! Here is my R code, inspired from @xnor answer :

a=scan();(n=a[1])*(m=a[2])*(n+1)*(m+1)/4

EDIT : In this version, R will ask twice for inputs.
(n=scan())*(m=scan())*(n+1)*(m+1)/4

cat(prod(choose(scan()+1,2))) is 29 bytes.

CJam, 12 10 Bytes
2 bytes saved thanks to Martin.
{_:)+:*4/}

Try it online!
This is a block that takes a list of 2 elements from the stack and leaves the solution on the stack. Usable full program for testing: riari+{_:)+:*4/}~.
Based off of xnor's outstanding python solution.
Explanation:
{_:)+:*4/}
{        } -- Define a block
 _:)       -- Duplicate list, increment all values in new list
    +      -- Join the two lists
     :*    -- Fold multiply over all 4 elements
       4/  -- Divide by 4

I think this works for 10 if you make input a list of two elements? {_:~+:*4/}

Actually, there's no need to use ~ at all in CJam. Just use ).

Matlab, 23 19 bytes
@(x)prod([x/2,x+1])

Implementation of the formula m*n*(m+1)*(n+1)/4
Usage: ans([m,n])

Java 7, 39 38 bytes
int c(int a,int b){return~a*a*b*~b/4;}

Java 8, 26 25 19 18 17 bytes
a->b->a*~a*b*~b/4

Based on @xnor's excellent answer. Multiple bytes saved thanks to @DavidConrad. Try it here.
Test code (Java 7):
Try it here.
class M{
  static int c(int a,int b){return~a*a*b*~b/4;}

  public static void main(String[] a){
    System.out.println(c(0, 0));
    System.out.println(c(1, 1));
    System.out.println(c(3, 3));
    System.out.println(c(4, 4));
    System.out.println(c(6, 7));
  }
}

Output:
0
1
36
100
588

You don't need that return and a->b-> is one byte shorter than (a,b)->.

I don't think you need the semicolon, either, since if you were passing the lambda into a method that took a Function<Integer, Function<Integer, Integer>> as a parameter, it wouldn't be followed by a semicolon.

I agree with @DavidConrad : I don't count the ending ; on single statement J8 lambdas.

@DavidConrad Sorry for the very late edit, but I only now noticed I read past your comment to remove the return .. Also, I almost never program in Java 8 (hence all my Java 7 answers), but how do I get a->b-> to work? Here is the ideone for the current case.

Sorry for the very late reply! You need to curry the function, so you need to change MathOperation.operation to take only one int, return a Function<Integer, Integer>, and when you call it, you initially pass only the first parameter, a, and then call .apply(b) on the Function. You also need to import java.util.function.Function. Here is an ideone with the changes.

@DavidConrad Thanks for the explanation and ideone. I've edited the post. :)

J, 8 bytes
2*/@:!>:

Usage:
   f =: 2*/@:!>:
   f 0 0
0
   f 3 3
36

This conversation has been moved to chat.

MATL, 6 bytes
tQ*2/p

Input is an array of the form [m,n].
Try it online!
Explanation
Direct computation based on the formula m*(m+1)*n*(n+1)/4.
t     % Input array [m,n] implicitly. Duplicate
Q     % Add 1 to each entry of the copy: gives [m+1,n+1]
*     % Multiply element-wise: gives [m*(m+1),n*(n+1)]
2/    % Divide each entry by 2: [m*(m+1)/2,n*(n+1)/2]
p     % Product of the two entries: m*(m+1)*n*(n+1)/4. Display implicitly

Labyrinth, 13 11 bytes
*?;*_4/!
):

Try it online!
Explanation
This also computes the product of the triangular numbers like most answers. The leading 2x2 block is a small loop:
*?
):

On the first iteration * doesn't do anything, so that the real loop order is this:
?   Read integer N from STDIN or 0 at EOF and push onto stack. If 0, exit the loop.
:   Duplicate N.
)   Increment.
*   Multiply to get N*(N+1).

The remaining code is just linear:
;   Discard the zero that terminated the loop.
*   Multiply the other two values.
_4  Push a 4.
/   Divide.
!   Print.

Labyrinth then tries to execute / again, which terminates the program due to a division by zero.

Ruby, 22 bytes
Stealing @xnor's trick and making a stabby-lambda:
r=->(m,n){m*n*~m*~n/4}

Example call:
r[6,7]     # => 588

Or as a proc, also 22 bytes:
proc{|m,n|m*n*~m*~n/4}

Which we could then call:
proc{|m,n|m*n*~m*~n/4}.call(6,7)     # => 588

You don't need to name it—anonymous functions are okay as per site convention

Pyke, 6 bytes
mh+Bee

Try it here!
mh     -    map(increment, input)
  +    -   ^ + input
   B   -  product(^)
    ee - ^ \ 4

This could use a breakdown, but I find it to be a work of art, personally.

05AB1E, 4 bytes
€LOP

Explanation
Uses the formula described at A096948
      # Implicit input, ex: [7,6]
€L    # Enumerate each, [[1,2,3,4,5,6,7],[1,2,3,4,5,6]]
  O   # Sum, [28,21]
   P  # Product, 588
      # Implicit display

Takes input as [n,m].
Try it online

Lua, 74 63 bytes
x,y=...n=0 for i=1,y do for j=i,i*x,i do n=n+j end end print(n)

Function takes input as number parameters.
Because of the way Lua is implemented, this is technically a function, with variable args, which can be called by wrapping it in a "function" statement, or loading it from source code using "loadstring"

I see that you have quite a lot of code there just for I/O. Perhaps it would be shorter to simply make a function that takes the two numbers and returns the answer, and remove all this unnecessary I/O code?

@Zwei I forgot that functions are allowed to take input by parameters. Thanks for pointing that out.

The function could be named something like "f" instead of the whole name "function" to save 7 more bytes

In Lua, the keyword "function" is required to declare a function. If no name is specified (ex: "function f()"), it's an anonymous function. (ex: "function()"). Therefore, the "function" is required for the code to work.

Oh, I forgot that lua works like that. My bad!

Pyth, 8 6 bytes
Two bytes saved thanks to @DenkerAffe.
*FmsSd

Input is expected as a list like [m,n]. Try it out here.
Explanation:
          Implicit assignment of Q to eval(input).
*         Multiplication.
 F        Splat the following sequence onto the arguments of the previous function.
  m       Map the following function of d over Q (Q is implicitly added to the end).
   s      Reduce the following list with addition, initial value of 0.
    Sd    Return range(1,d+1).

You can use F instead of .* and remove the Q since it is added implictly.

I knew about F but I couldn't figure out how to use it and figured I needed to use .* instead... Thanks!

C#, 19 bytes
(n,m)=>m*n*~m*~n/4;

An anonymous function based off of @xnor's answer.

Cheddar, 23 bytes
m->n->m*(m+1)*n*(n+1)/4

n*(n+1) can be golfed to n^2+n

@Downgoat What about the parentheses?

oh >_> yeah. sorry, nvm, wasn't thinking

try currying the function. m->n->...

Brain-Flak, 84 80 bytes
({}<>)({({})<({}[()])>}{})<>({({})<({}[()])>}{}[()]){<>(({}))<>({}[()])}<>({{}})

Try it online!
Probably very sub-optimal, especially because of the code reuse regarding triangle numbers, but at least we have a Brain-Flak solution that works.
Sadly it seems to fail by looping infinitely with the 0 0 testcase but all others work fine.

Convex, 7 bytes
I know that this can be smaller, I just can't figure out how yet...
_:)+×½½

Try it online!. Uses the CP-1252 encoding.

Pyt, 3 bytes
←△Π

Explanation:
←       Get input
 △      Get triangle numbers
  Π     Array product
        Implicit output

Try it online!

APL (Dyalog), 9 bytes
×/+/∘⍳¨∘⊢

Try it online!