def step_5b(w):
 if (w.endswith('ll') and R2(w).endswith('l')):
  return w[:(-1)]
 return w

def step_5b ( w ) : if ( w . endswith ( 'll' ) and R2 ( w ) . endswith ( 'l' ) ) : return w [ : ( - 1 ) ] return w
step 5b strips suffix -l if preceded by l and multiple vowel-consonant pairs .