Skip to main content
added 65 characters in body
Source Link
att
  • 21.7k
  • 2
  • 16
  • 62

Wolfram Language (Mathematica), 6262 60 bytes

#/.Table[#⋂##&@@#~Select~MemberQ@ii||i(i#⋂##&@@#~Select~MemberQ@ii||i->Set@$,{i,Max@#}]&)/@Join@@#&

Try it online!Try it online!

The private-use character is⋂ are \[Function]\[Intersection]\[VectorLessEqual].

   Table[(i                                     ,{i,Max@#}]  )/@Join@@# for positiveall i up to thein maxinput
#/.                                   i->Set@$              remove i if
         #⋂##&@@                                              intersection of
                #~Select~MemberQ@i                              lists containing i
                                  i||                        not all <=i≤i

Wolfram Language (Mathematica), 62 bytes

#/.Table[#⋂##&@@#~Select~MemberQ@ii||i->Set@$,{i,Max@#}]&

Try it online!

The private-use character is \[VectorLessEqual].

   Table[                                     ,{i,Max@#}]   for positive i up to the max
#/.                                   i->Set@$              remove i if
         #⋂##&@@                                              intersection of
                #~Select~MemberQ@i                              lists containing i
                                  i||                        not all <=i

Wolfram Language (Mathematica), 62 60 bytes

#/.(i#⋂##&@@#~Select~MemberQ@ii||i->Set@$)/@Join@@#&

Try it online!

⋂ are \[Function]\[Intersection]\[VectorLessEqual].

   (i                                     )/@Join@@# for all i in input
#/.                                i->Set@$             remove i if
      #⋂##&@@                                             intersection of
             #~Select~MemberQ@i                             lists containing i
                               i||                       not all ≤i
Source Link
att
  • 21.7k
  • 2
  • 16
  • 62

Wolfram Language (Mathematica), 62 bytes

#/.Table[#⋂##&@@#~Select~MemberQ@ii||i->Set@$,{i,Max@#}]&

Try it online!

The private-use character is \[VectorLessEqual].

   Table[                                     ,{i,Max@#}]   for positive i up to the max
#/.                                   i->Set@$              remove i if
         #⋂##&@@                                              intersection of
                #~Select~MemberQ@i                              lists containing i
                                  i||                        not all <=i