You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
378 B
17 lines
378 B
# join.awk --- join an array into a string
|
|
#
|
|
# Arnold Robbins, arnold@skeeve.com, Public Domain
|
|
# May 1993
|
|
|
|
function join(array, start, end, sep, result, i)
|
|
{
|
|
if (sep == "")
|
|
sep = " "
|
|
else if (sep == SUBSEP) # magic value
|
|
sep = ""
|
|
result = array[start]
|
|
for (i = start + 1; i <= end; i++)
|
|
result = result sep array[i]
|
|
return result
|
|
}
|