while ($formula =~ s|([a-z]+)|$data{$1}//' '|e) { push @error, $1 unless exists $data{$1};