Comment

Comment by t1m

I wrote a language called T for Bell Northern Research, not knowing there was already another T language based on Scheme. The language was used for black box testing testing of terminal interfaces, and so needed good string handling.

One aspect of the language was that Unix regular expressions were a built-in type, and so were associate arrays. These two features worked together in a cool way:

  x['hi there'] = 5
  x['hello'] = 2

  # regular expressions are enclosed in `backquotes`
  x[`hell.`] == [2]
  x[`h.*`] == [5, 2]
parent t1m 9 years ago

No comments yet

Be the first to share your thoughts.

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton