Re: Notation for sets in n3

> 
> How about adding at least one comma to a list syntax to give set 
> syntax, so that the same punctuation is used for lists.  The comma 
> could be thought of as adding unorderedness.  (The other use of a comma 
> occurs in RDF statements with multiple objects - and the objects are of 
> course nor ordered)
> 
>   (,)  The null set
> (  :a  ,)  The set with  only :a in it
> ( :a, :b, :c)  The set with :a , :b and :c in it

That's rather elegant.  I'd suggest a semicolon intead of a comma,
though, since so many list syntaxes (everything I can think of other
than LISP and n3) use commas.   Another option is "|".    The mnemonic
for me comes mostly from semi-colon being Prolog's "or", and a set is
kind of vaguely a little like an alternation.  :-)

What's the current n3 meaning of { <a>, <b> }?  Is that something
really useful?  I like { } for sets (since that's what I learn in my
math classes) and formulas are very similar to sets of triples.

     -- sandro

Received on Monday, 2 August 2004 22:55:00 UTC