Expression

Time Limit: 1000ms
Memory Limit: 32768KB
This problem will be judged on HDU. Original ID: 2646
64-bit integer IO format: %I64d      Java class name: Main

Description

As a shopkeeper of a restaurant,everyday ,dandelion's mother needs to calculate the incomes.Sometimes,she may make some mistakes.So dandelion wants you to write a program to help her calculate the value of some expressions.
You may consider every expression is made of :left parenthesis '(' ,right parenthesis ')' , plus sign '+' , subtraction sign '-' , multiplication sign '*' ,positive sign '+' ,and negative sign '-'.There is no precursor 0.The length of expression will not exceed 100.The value produced during the calculating will not exceed 10^9.Every expression is legal.Ie. ((10+(-100))) ,-(-1),-3*(+5+7*2)-(0) ,-0 ,(-3)*(-5+7) are legal,while 1+-7 ,--3+8 ,-3+() are illegal.

Input

There are several cases,every line contains a expression.

Output

For every case ,print the answer of the expression.

Sample Input

-3*(+5-7*2)-(0)

Sample Output

27

Source

Language: 
Theme: 
Share Code? 

Powered by NB231 | Current Style: .