> a = new Interval[2,3]
>
> But that's slightly cumbersome. So, what notation can we use for
> intervals that's:
>
> 1.) Possible to type on an ordinary keyboard
> 2.) Uses only ASCII characters
> 3.) Unambiguous
> 4.) Doesn't force change of existing syntax.
> 5.) Quick to type
> 6.) Not too visually noisy
> 7.) Visually distinguishable from other constructs 8.) It
> should still kinda look like [2, 3]
....
> So, who can come up with the best way to write intervals
> concisely?
What about A .. B?
Examples:
for i = 0 .. 100 ; do
fa[i] = f[i] + f[i-1];
done
lunchtime = 12am .. 1pm
if x in lunchtime; then
do_lunchtime_event ;
endif
timeperiods = [ 8am .. 9am, 12pm .. 1pm, 5:30pm .. 6:30pm ];