I have this sample grepl()
code that differentiates between male and females name. The following code is given and it works but I am unable to understand how it works.
name = c("Braund, Mr. Owen Harris",
"Cumings, Mrs. John Bradley (Florence Briggs Thayer)")
grepl("\\(.*?\\)", name)
# [1] FALSE TRUE