For the case when word is smaller than 4 characters, we should not look at the 3rd or 4th character before checking the previous ones, otherwise we'd at best read uninitialized data, at worse non-existing data.