help-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-bash] Which is preferred? '`' or '$('?


From: Clark WANG
Subject: Re: [Help-bash] Which is preferred? '`' or '$('?
Date: Tue, 12 Mar 2013 09:49:14 +0800

On Tue, Mar 12, 2013 at 8:59 AM, Peng Yu <address@hidden> wrote:
Hi,

It seems that $( is a more recent form as it is mentioned in the
manual "When the old-style backquote form of substitution is used
...". Since these two forms, to a certain extend, are the same and $(
is introduced later, is $( preferred?

$() is more readable and it's much easier for nesting. For example, think how you can rewrite following statement with backquotes:

  var=$(echo $(echo $(echo $(echo foo))))


--
Regards,
Peng



reply via email to

[Prev in Thread] Current Thread [Next in Thread]