Determine Duplicate Elements in the Last Position
duplicated_last(x)
x
character
logical value
x=c(1,3,2,1,2) duplicated(x) duplicated_last(x)