-module(helloworld). -export([start/0]). start() -> Sum1 = sum("accentor", "systemic"), io:fwrite("~p~n", [Sum1]). sum(L1, L2) -> Zipped = lists:zip(L1, L2), Mapped = lists:map( fun ({A, B}) -> if B - A > 0 -> B - A - 1; true -> B - A + 1 end end, Zipped), lists:sum(Mapped).
We use cookies to provide and improve our services. By using our site, you consent to our Cookies Policy. Accept Learn more