import java.util.Arrays; import java.util.LinkedList; import java.util.Scanner; public class Main { public static void main(String[] args){ Scanner sc = new Scanner(System.in); char[] inputs = sc.next().toCharArray(); int pos = 0; int current = 0; while('0' <= inputs[pos] && inputs[pos] <= '9'){ current *= 10; current += Character.getNumericValue(inputs[pos]); pos++; } while(pos < inputs.length){ boolean plus = inputs[pos++] == '*'; int snd = 0; while(pos < inputs.length && '0' <= inputs[pos] && inputs[pos] <= '9'){ snd *= 10; snd += Character.getNumericValue(inputs[pos]); pos++; } if(plus){ current += snd; }else{ current *= snd; } } System.out.println(current); } }