Why 0 is true but false is 1 in bash?

Posted by httpinterpret on Stack Overflow See other posts from Stack Overflow or by httpinterpret
Published on 2010-05-29T04:50:49Z Indexed on 2010/05/29 4:52 UTC
Read the original article Hit count: 248

Filed under:
|
false; echo $?

The above will output 1,which is contradictory with all other programming languages I know.

Any reason in this?

© Stack Overflow or respective owner

Related posts about bash

Related posts about boolean