Say you have two lists:
listA = {a, b, c}
listB = {d, e, f}
How would you produce a listC that equates each of the two's elements, ie.
listC = {a == d, b == e, c == f} ?
I know, it's very easy, but somehow I've already spent an slightly embarrassing amount of time on this. I suspect it will involve Map, but can't seem to get the elements to behave together per each element. It seems to just Append the two together for some reason.
SetAttributes[listA, Listable]
SetAttributes[listB, Listable]
seems promising given this: http://reference.wolfram.com/mathematica/ref/Listable.html
Thread[listA == listB]– rm -rf Jun 12 '13 at 00:45listAis equal tolistB, thenThread[listA == listB]will return justTrue. In that case, this:MapThread[Equal, {listA, listB}]. – Michael E2 Jun 12 '13 at 05:37Thread. – Ghersic Jun 12 '13 at 05:49