Quantcast
Viewing latest article 1
Browse Latest Browse All 5

Answer by E. Chan-López for How can I transform the string to a list?

b1 = {a, b, c, d, e};b2 = {1, 2, 3, 4, 5};

Using Thread and MapApply:

#1 <> " - " <> #2 & @@@ Map[ToString, Thread[{b1, b2}], {2}]

Result:

{"a - 1", "b - 2", "c - 3", "d - 4", "e - 5"}


Viewing latest article 1
Browse Latest Browse All 5

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>