LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Placeholders for values not avalible : (https://www.linuxquestions.org/questions/linux-newbie-8/placeholders-for-values-not-avalible-672281/)

jack olson 09-25-2008 07:35 AM

Placeholders for values not avalible :
 
Being new to the scripting in linux , I have tried using examples in Tutorial. echo $[x"*"y] doesn't resolve, it just displays $[x"*"y].
expr doesn't work ether.If I use values it works. What am I not doing.
Thank you , jack

CRC123 09-25-2008 08:13 AM

Code:

x=2
y=3
echo $[x*y]
# gives
6

You don't need the quotes on the asterisk.


All times are GMT -5. The time now is 04:18 PM.