Question: I have this code:

```
field = string.Format(Str, value1, value2,
        found == true ? fieldName : "", found  == true ? "product" : "");

```

Is there a way to combine the two `found == true` ternary operation into a more succinct piece of code?

Answer: 
You don't need the `== true` bit:

```
field = string.Format(Str, value1, value2, found ? fieldName : "", found ? "product" : "");

```

However, in my view the following is easier to read:

```
if (found) {
    field = string.Format(Str, value1, value2, fieldName, "product");
}
else {
    field = string.Format(Str, value1, value2, "", "");
}

```
Comparing to true is unnecessary:

```
field = string.Format(Str, value1, value2, found ? fieldName : "", found ? "product" : "");

```