English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
This method is used to split the binary list according to the specified index position.
split_binary(binarylst,index)
binarylst −This is the binary list that needs to be split.
index −This is the index position where the list should be split.
Return the split binary string.
-module(helloworld). -export([start/0]). start(), -> io:fwrite("~p~n",[split_binary(<<1,2,3,4,5>>>,3).
When we run the above program, we will get the following result.
{<<1,2,3>>>,<<4,5>>}