python split string and take first part code example Example: python split by first match s.split('mango', 1)[1]