Collect and sort square numbers in ascending order from three lists: Difference between revisions

(Added XPL0 example.)
Line 163:
println(squares)
</lang>
=={{header|Mathematica}} / {{header|Wolfram Language}}==
<lang Mathematica>llist1 = {3, 4, 34, 25, 9, 12, 36, 56, 36};
list2 = {2, 8, 81, 169, 34, 55, 76, 49, 7};
list3 = {75, 121, 75, 144, 35, 16, 46, 35};
Sort@Select[Join[list1, list2, list3], IntegerQ[Sqrt[#]] &]</lang>
 
{{out}}<pre>
{4,9,16,25,36,36,49,81,121,144,169}
</pre>
 
=={{header|ooRexx}}==
Anonymous user