list1 <- list(a = 1:3, b = c(letters[1:3]), d = 4)
list2 <- list(d = "nom", a = 4:6, c = "om")
How to merge lists into one so that the lists always merge correctly?
Desired output:
combined_list <- list(a = 1:6, b = c(letters[1:3]), c = "om", d = c(4, "nom"))
source
to share