Question: I'm trying to use Regex to match the method to my step definiton.
I want the step to be matched to any of the following and capture the number group.

1. the fuel percent is 74
2. the fuel percent should be 74
3. fuel percent is 74

This is the regex expression i'm using 
@Then(".*\bfuel\b.*\bpercent\b.\* (\d+)")

But it doesnt seem to match or capture the value.
It says please implement the missing steps

```
@Then("the fuel percent should be {int}")
public void the_fuel_percent_should_be(Integer int1) {
    // Write code here that turns the phrase above into concrete actions
    throw new cucumber.api.PendingException();
}

```

Answer: 
Gherkin:

```
the fuel percent is '74'
the fuel percent should be '74' fuel
percent is '74'

```

Java:

```
@Then(".*fuel percent (is|should be) '(.*)'")
public void the_fuel_percent_should_be(String type, Integer int1) {
    // Write code here that turns the phrase above into concrete actions
    throw new cucumber.api.PendingException();
}

```

Regexp online demo [here](https://regex101.com/r/Vvqu3n/1).
The regex for matching the 3 examples you gave would be:

```
.*fuel.*percent.*\d{1,3}

```