OMG!!!! I found a video on my most hated language, #tcl. If you do a project with that language, suddenly any criticizing about other languages becomes more like a funny thing to do and not an actual frustration. The fact that something like that is allowed to exist in production is insane. Hear me out:
- everything is a string
- {} is a code block but also your argument brackets so, since you do a lot of function passing a code can fastly look like this:
proc wrap {x} {
return {{wrapped} {$x}}
}
proc process {items} {
foreach item $items {
if {[string length [lindex $item 1]] > 3} {
puts [join [wrap [lindex $item 1]] { -> }]
}
}
}
set data {{name John} {age 30} {city {New York}}}
process $data
PS: I when a bit arch on it for the fun but I love this language as an experiment. I don't really like to write it tho. I know there is a community out there so it's probably a good language for some brains, not mine.
