|
|
|
|
|
by kazinator
4297 days ago
|
|
That appalled user would have a heart attack at Awk, a language in which a previously unseen variable serves as zero or an empty string. count++ # if count doesn't exist, it becomes 1
A previously unseen array reference materializes automatically too: count[$1]++
(I think this is garbage too, but it leads to throwaway programs that are very concise. If you write anything large, it's going to bite you on the butt: mispelled[foo] += bar; # wee
|
|