[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
arithmetic operations
From: |
Alexander Kshevetskiy |
Subject: |
arithmetic operations |
Date: |
Tue, 24 Jan 2006 17:58:49 +0300 |
Configuration Information [Automatically generated, do not change]:
Machine: i686
OS: linux-gnu
Compiler: i686-pc-linux-gnu-gcc
Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='i686'
-DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='i686-pc-linux-gnu'
-DCONF_VENDOR='pc' -DLOCALEDIR='/usr/share/locale' -DPACKAGE='bash' -DSHELL
-DHAVE_CONFIG_H -I. -I. -I./include -I./lib -O2 -march=athlon-xp
-fomit-frame-pointer
uname output: Linux radio 2.6.14-gentoo-r2 #3 PREEMPT Wed Dec 14 22:38:58 MSK
2005 i686 AMD Athlon(TM) XP 1600+ AuthenticAMD GNU/Linux
Machine Type: i686-pc-linux-gnu
Bash Version: 3.1
Patch Level: 5
Release Status: release
Description:
1)
let a=(a+500)/1000
does not work after update from 3.0 to 3.1, while
let a=\(a+500\)/1000
is working
2)
a=8000; a=$[(a+500)/1000]; ---> 9
a=8000; let a=\(a+500\)/1000; ---> 8
this way, we can show that 2x2=3.
- arithmetic operations,
Alexander Kshevetskiy <=