2/ maybe also throw a "2^ _1 *" near the end, so that any value other than 0 is a negative number and the whole thing can be returned as a unix status code
-
-
Show this threadThanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
don't think that works -- it'd return true on ")(" and similar cases
-
echo
$input_string | sed 's/(/0 /g' | sed 's/)/+ /g' | sed 's/^/0 /' | sed 's/$/f/' | dc 1>tmp1 2>tmp2 ; if [[ `wc -l tmp1 | cut -d ' ' -f 1` == 1 ]] && [[ `wc -l tmp2 | cut -d ' ' -f 1` == 0 ]] ; then echo "true" ; else echo "false" ; fi ; rm tmp1 tmp2 - Show replies
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.