<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Odd problem with &amp;quot;let&amp;quot; in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/odd-problem-with-quot-let-quot/m-p/3187505#M796166</link>
    <description>I know this can be done as follows with bc, but I need some classes on shell scripting.&lt;BR /&gt;export MEM_FREE=`echo "600426*4096"|bc`&lt;BR /&gt;&lt;BR /&gt;echo $MEM_FREE</description>
    <pubDate>Tue, 10 Feb 2004 07:53:40 GMT</pubDate>
    <dc:creator>RAC_1</dc:creator>
    <dc:date>2004-02-10T07:53:40Z</dc:date>
    <item>
      <title>Odd problem with "let"</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/odd-problem-with-quot-let-quot/m-p/3187503#M796164</link>
      <description>Hello everybody,&lt;BR /&gt;&lt;BR /&gt;I'm facing to the following problem in my last shell script:&lt;BR /&gt;&lt;BR /&gt;Everybody knows that:&lt;BR /&gt;&lt;BR /&gt;600426*4096=2459344896&lt;BR /&gt;&lt;BR /&gt;...everybody but let...&lt;BR /&gt;&lt;BR /&gt;#let MEM_FREE=600426*4096&lt;BR /&gt;#echo $MEM_FREE&lt;BR /&gt;-1835622400&lt;BR /&gt;&lt;BR /&gt;Is there any limitation with let? (i.e. 2147483648 = 2Gb)&lt;BR /&gt;How can assign the correct value to MEM_FREE?&lt;BR /&gt;&lt;BR /&gt;Thanks a lot for your help!&lt;BR /&gt;&lt;BR /&gt;Simone</description>
      <pubDate>Tue, 10 Feb 2004 07:43:12 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/odd-problem-with-quot-let-quot/m-p/3187503#M796164</guid>
      <dc:creator>Simone Benzi_1</dc:creator>
      <dc:date>2004-02-10T07:43:12Z</dc:date>
    </item>
    <item>
      <title>Re: Odd problem with "let"</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/odd-problem-with-quot-let-quot/m-p/3187504#M796165</link>
      <description>Looks like the max is :&lt;BR /&gt;&lt;BR /&gt;$ echo `expr 524287 * 4096`&lt;BR /&gt;2147479552&lt;BR /&gt;&lt;BR /&gt;There is not a higher value possible. Don't know the cause. Maybe this number does anything to someone.&lt;BR /&gt;&lt;BR /&gt;Regs David</description>
      <pubDate>Tue, 10 Feb 2004 07:52:14 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/odd-problem-with-quot-let-quot/m-p/3187504#M796165</guid>
      <dc:creator>David_246</dc:creator>
      <dc:date>2004-02-10T07:52:14Z</dc:date>
    </item>
    <item>
      <title>Re: Odd problem with "let"</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/odd-problem-with-quot-let-quot/m-p/3187505#M796166</link>
      <description>I know this can be done as follows with bc, but I need some classes on shell scripting.&lt;BR /&gt;export MEM_FREE=`echo "600426*4096"|bc`&lt;BR /&gt;&lt;BR /&gt;echo $MEM_FREE</description>
      <pubDate>Tue, 10 Feb 2004 07:53:40 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/odd-problem-with-quot-let-quot/m-p/3187505#M796166</guid>
      <dc:creator>RAC_1</dc:creator>
      <dc:date>2004-02-10T07:53:40Z</dc:date>
    </item>
    <item>
      <title>Re: Odd problem with "let"</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/odd-problem-with-quot-let-quot/m-p/3187506#M796167</link>
      <description>Hi&lt;BR /&gt;&lt;BR /&gt;For big numbers use bc in your script&lt;BR /&gt;&lt;BR /&gt;You are hitting a known problem;&lt;BR /&gt;&lt;BR /&gt;#!/usr/bin/sh&lt;BR /&gt;#You could use the 'two way pipe' to the program to do all your math operations,&lt;BR /&gt; like this:&lt;BR /&gt;# This starts bc with a two-way pipe&lt;BR /&gt;bc |&amp;amp;&lt;BR /&gt;# print -p writes to the pipe&lt;BR /&gt;print -p scale=4&lt;BR /&gt;print -p 3/4&lt;BR /&gt;# read -p reads from the pipe&lt;BR /&gt;read -p myvar&lt;BR /&gt;echo $myvar&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;           Steve Steel</description>
      <pubDate>Tue, 10 Feb 2004 07:54:42 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/odd-problem-with-quot-let-quot/m-p/3187506#M796167</guid>
      <dc:creator>Steve Steel</dc:creator>
      <dc:date>2004-02-10T07:54:42Z</dc:date>
    </item>
    <item>
      <title>Re: Odd problem with "let"</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/odd-problem-with-quot-let-quot/m-p/3187507#M796168</link>
      <description>Simone,&lt;BR /&gt;&lt;BR /&gt;check this link: &lt;A href="http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=19128" target="_blank"&gt;http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=19128&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;There is indeed a limitation.&lt;BR /&gt;The link also contains suggestions.&lt;BR /&gt;&lt;BR /&gt;JP.</description>
      <pubDate>Tue, 10 Feb 2004 07:57:25 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/odd-problem-with-quot-let-quot/m-p/3187507#M796168</guid>
      <dc:creator>Jeroen Peereboom</dc:creator>
      <dc:date>2004-02-10T07:57:25Z</dc:date>
    </item>
    <item>
      <title>Re: Odd problem with "let"</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/odd-problem-with-quot-let-quot/m-p/3187508#M796169</link>
      <description>Thank you everybody!&lt;BR /&gt;I'll use "bc" in my scripts.&lt;BR /&gt;&lt;BR /&gt;Points assigned...&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Simone</description>
      <pubDate>Tue, 10 Feb 2004 08:02:14 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/odd-problem-with-quot-let-quot/m-p/3187508#M796169</guid>
      <dc:creator>Simone Benzi_1</dc:creator>
      <dc:date>2004-02-10T08:02:14Z</dc:date>
    </item>
  </channel>
</rss>

