Logo

Programming-Idioms

History of Idiom 46 > diff from v23 to v24

Edit summary for version 24 by :
New Erlang implementation by user [elbrujohalcon]

Version 23

2015-11-30, 12:37:29

Version 24

2015-12-18, 02:49:37

Idiom #46 Extract beginning of string (prefix)

Create string t consisting of the 5 first characters of string s.

Idiom #46 Extract beginning of string (prefix)

Create string t consisting of the 5 first characters of string s.

Code
[A, B, C, D, E | _] = S,
T = [A, B, C, D, E].
Doc URL
http://erlang.org/doc/reference_manual/patterns.html