On Mon, Oct 06, 2025 at 06:17:46 +0000, w f wrote:
> if [[ (-n $a && $c <= $d) || (-n $b && $c == $d) ]] ; then echo ok ; else
> echo no ; fi
> -bash: expected ')'
> -bash: syntax error near `$d)'
>
> Why does this give a syntax error?
Because you need spaces around ( and ) in that command.