#!/bin/bash
s='bob mary mike bill kim jim john'
perl -lane 'while (/(?=\b(\p{L}+\s+\p{L}+))/g) {print $1}' <<< "$s"