Having this vector:
vector <- c("236", "234", "", "12", "24", "3")
[1] "236" "234" "" "12" "24" "3"
I would like to check how many consecutive numbers there are in each element.
Expected output:
2 3 0 2 0 0
I have no idea how to do this!