Hi Ramana, Thank you very much, I’ll follow your suggestions.
Regards, Chun > Il giorno 02 lug 2017, alle ore 10:23, Ramana Kumar > <ramana.ku...@cl.cam.ac.uk> ha scritto: > > Sure, that's fine. I probably wouldn't even define such a constant but would > instead use ``FILTER ((<>) x) ls`` in place. > > Stylistically it's usually better to use Define instead of new_definition, > and to name defining theorems with a "_def" suffix. I'd also keep the name > short like "DELETE" or even "delete". > > On 2 Jul 2017 17:04, "Chun Tian (binghe)" <binghe.l...@gmail.com > <mailto:binghe.l...@gmail.com>> wrote: > Hi, > > It seems that ListTheory didn’t provide a way to remove elements from list? > What’s the recommended way to do such operation? Should I use FILTER, for > example, like this? > > val DELETE_FROM_LIST = new_definition ( > "DELETE_FROM_LIST", ``DELETE_FROM_LIST x list = (FILTER (\i. ~(i = x)) > list)``); > > Regards, > > Chun > > > ------------------------------------------------------------------------------ > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > <http://sdm.link/slashdot> > _______________________________________________ > hol-info mailing list > hol-info@lists.sourceforge.net <mailto:hol-info@lists.sourceforge.net> > https://lists.sourceforge.net/lists/listinfo/hol-info > <https://lists.sourceforge.net/lists/listinfo/hol-info> >
signature.asc
Description: Message signed with OpenPGP using GPGMail
------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________ hol-info mailing list hol-info@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hol-info