|
From: | Chet Ramey |
Subject: | Re: Logical expression works does not work as expected |
Date: | Tue, 31 Dec 2024 11:55:32 -0500 |
User-agent: | Mozilla Thunderbird |
On 12/28/24 3:23 PM, Lawrence Velázquez wrote:
On Fri, Dec 27, 2024, at 6:47 PM, Greg Wooledge wrote:You might have been raised on some other language where the && and || operators have different precedence. In the shell language, they have the same precedence.However, the && and || arithmetic operators do have C-like precedence.
If you're going to add arithmetic to the shell language, why not add it with the precedence and syntax most comfortable to its users? -- ``The lyf so short, the craft so long to lerne.'' - Chaucer ``Ars longa, vita brevis'' - Hippocrates Chet Ramey, UTech, CWRU chet@case.edu http://tiswww.cwru.edu/~chet/
OpenPGP_signature.asc
Description: OpenPGP digital signature
[Prev in Thread] | Current Thread | [Next in Thread] |