# : versus :=

I am going through the Fast introduction for programmers tutorial on Mathematica. The page on patterns has the below line:

x_ (short for x:_) stands for a pattern whose value will be named x

shouldn't it be '(short for x:=_)' which would suggest that pattern matched by _ will be bound to the variable x?

• No, not a typo; compare the results of FullForm[x_] and FullForm[x : _]. – J. M. is in limbo Sep 24 '18 at 20:36
• Also, please do not use the bugs tag until other people have already confirmed that it is one. – J. M. is in limbo Sep 24 '18 at 20:37

: and := are two different operations in Mathematica. :, shorthand for Pattern, is used to represent some form, while :=, short for SetDelayed is used to say "Okay, replace any instance of the left hand side with the right hand side and re-evaluate rhs at every replacement".

In the context of x_ vs x:=_, x_ is syntactically/manifestly equivalent to x:_ or x:Blank[] (i.e. Represent by x any single entity.), whereas x:=_ represents "At every occurrence of anything of the form x replace it with the pattern object Blank[]".

x := _; x
Clear@x; x : _


_

x_

• Thanks for editing the question. The question makes sense now and can help others too. – gaganso Sep 24 '18 at 21:45