[erlang-questions] Lists in recursion

harsha sri harsha.pic@REDACTED
Fri Mar 27 13:42:23 CET 2015


Hi,

Is it possible to add dynamically add elements to List in recursion?

ex: List = [1,2,3]

lists:foreach...

.....
List = [4 | List]
....
(anotherlist).

Finally i am expecting in List: [1,2,3,4]

Thanks & Regards,
Harsha.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20150327/6935c569/attachment.htm>


More information about the erlang-questions mailing list