discuss@lists.openscad.org

OpenSCAD general discussion Mailing-list

View all threads

Creating a new list

JW
Joe Weinpert
Sun, May 25, 2025 2:02 AM

I'm working with a multiple list that contains 31 individual lists. My goal
is to deduplicate each of these 31 lists and then compile the results into
a new multiple list.

I have a couple of questions regarding this process:

  1. Does the deduplicate() function process the lists within a multiple
    list individually?
  2. Is it possible to write a modified list back into an existing multiple
    list?
  3. Could you provide guidance on how to create a new multiple list and
    append the deduplicated results of each of the 31 original lists to it?

Thanks for your help!

Joe Weinpert
joe.weinpert@gmail.com
www.jwstudio.art http://jwstudio.art

I'm working with a multiple list that contains 31 individual lists. My goal is to deduplicate each of these 31 lists and then compile the results into a new multiple list. I have a couple of questions regarding this process: 1. Does the `deduplicate()` function process the lists within a multiple list individually? 2. Is it possible to write a modified list back into an existing multiple list? 3. Could you provide guidance on how to create a new multiple list and append the deduplicated results of each of the 31 original lists to it? Thanks for your help! Joe Weinpert joe.weinpert@gmail.com www.jwstudio.art <http://jwstudio.art>
AM
Adrian Mariano
Sun, May 25, 2025 2:21 AM
  1. No, deduplicate operates on a single list.
  2. It is never possible to "write something back" somewhere.  You always
    have to rewrite a new version with the desired changes.
  3. I think you want something like this:  newlist = [for(sublist=list)
    deduplicate(sublist)]

On Sat, May 24, 2025 at 10:04 PM Joe Weinpert via Discuss <
discuss@lists.openscad.org> wrote:

I'm working with a multiple list that contains 31 individual lists. My
goal is to deduplicate each of these 31 lists and then compile the results
into a new multiple list.

I have a couple of questions regarding this process:

  1. Does the deduplicate() function process the lists within a multiple
    list individually?
  2. Is it possible to write a modified list back into an existing multiple
    list?
  3. Could you provide guidance on how to create a new multiple list and
    append the deduplicated results of each of the 31 original lists to it?

Thanks for your help!

Joe Weinpert
joe.weinpert@gmail.com
www.jwstudio.art http://jwstudio.art


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org

1. No, deduplicate operates on a single list. 2. It is never possible to "write something back" somewhere. You always have to rewrite a new version with the desired changes. 3. I think you want something like this: newlist = [for(sublist=list) deduplicate(sublist)] On Sat, May 24, 2025 at 10:04 PM Joe Weinpert via Discuss < discuss@lists.openscad.org> wrote: > I'm working with a multiple list that contains 31 individual lists. My > goal is to deduplicate each of these 31 lists and then compile the results > into a new multiple list. > > I have a couple of questions regarding this process: > > 1. Does the `deduplicate()` function process the lists within a multiple > list individually? > 2. Is it possible to write a modified list back into an existing multiple > list? > 3. Could you provide guidance on how to create a new multiple list and > append the deduplicated results of each of the 31 original lists to it? > > Thanks for your help! > > Joe Weinpert > joe.weinpert@gmail.com > www.jwstudio.art <http://jwstudio.art> > > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org >
JW
Joe Weinpert
Sun, May 25, 2025 3:46 AM

Yes Adrian ... that worked, thanks!

AI didn't help on this one. 😏

Joe Weinpert
joe.weinpert@gmail.com
www.jwstudio.art http://jwstudio.art

On Sat, May 24, 2025 at 10:22 PM Adrian Mariano via Discuss <
discuss@lists.openscad.org> wrote:

  1. No, deduplicate operates on a single list.
  2. It is never possible to "write something back" somewhere.  You always
    have to rewrite a new version with the desired changes.
  3. I think you want something like this:  newlist = [for(sublist=list)
    deduplicate(sublist)]

On Sat, May 24, 2025 at 10:04 PM Joe Weinpert via Discuss <
discuss@lists.openscad.org> wrote:

I'm working with a multiple list that contains 31 individual lists. My
goal is to deduplicate each of these 31 lists and then compile the results
into a new multiple list.

I have a couple of questions regarding this process:

  1. Does the deduplicate() function process the lists within a multiple
    list individually?
  2. Is it possible to write a modified list back into an existing multiple
    list?
  3. Could you provide guidance on how to create a new multiple list and
    append the deduplicated results of each of the 31 original lists to it?

Thanks for your help!

Joe Weinpert
joe.weinpert@gmail.com
www.jwstudio.art http://jwstudio.art


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org

Yes Adrian ... that worked, thanks! AI didn't help on this one. 😏 Joe Weinpert joe.weinpert@gmail.com www.jwstudio.art <http://jwstudio.art> On Sat, May 24, 2025 at 10:22 PM Adrian Mariano via Discuss < discuss@lists.openscad.org> wrote: > 1. No, deduplicate operates on a single list. > 2. It is never possible to "write something back" somewhere. You always > have to rewrite a new version with the desired changes. > 3. I think you want something like this: newlist = [for(sublist=list) > deduplicate(sublist)] > > On Sat, May 24, 2025 at 10:04 PM Joe Weinpert via Discuss < > discuss@lists.openscad.org> wrote: > >> I'm working with a multiple list that contains 31 individual lists. My >> goal is to deduplicate each of these 31 lists and then compile the results >> into a new multiple list. >> >> I have a couple of questions regarding this process: >> >> 1. Does the `deduplicate()` function process the lists within a multiple >> list individually? >> 2. Is it possible to write a modified list back into an existing multiple >> list? >> 3. Could you provide guidance on how to create a new multiple list and >> append the deduplicated results of each of the 31 original lists to it? >> >> Thanks for your help! >> >> Joe Weinpert >> joe.weinpert@gmail.com >> www.jwstudio.art <http://jwstudio.art> >> >> _______________________________________________ >> OpenSCAD mailing list >> To unsubscribe send an email to discuss-leave@lists.openscad.org >> > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org >