func_code_string: #include <bits/stdc++.h>   using namespace std;   int main(int argc, char **argv) {     ios_base::sync_with_stdio(false);     string s;     cin >> s;     int n = s.size();     long long maxDiff = 0;     long long ans = 0;     int x;     if (n == 1) {       cout << s << endl;       return 0;     }     vector<pair<char, vector<long long> > > a;     char t =  o ;     for (int i = 0; i < n; i += 2) {       x = s[i] -  0 ;       if (((i > 0) && (s[i - 1] ==  * )) || ((i < n - 1) && (s[i + 1] ==  * ))) {         if (t !=  * ) {           t =  * ;           a.push_back(make_pair(t, vector<long long>(1, x)));         } else {           a.back().second.push_back(a.back().second.back() * x);         }         if ((i < n - 1) && (s[i + 1] ==  + )) {           t =  o ;         }       } else {         if (t !=  + ) {           t =  + ;           a.push_back(make_pair(t, vector<long long>(1, x)));         } else {           a.back().second.push_back(a.back().second.back() + x);         }       }     }     n = a.size();     vector<long long> b(n);     for (int i = 0; i < n; i++) {       b[i] = a[i].second.back();       if (i) {         b[i] += b[i - 1];       }     }     ans = b[n - 1];     maxDiff = 0;     for (int i = 0; i < n; i++) {       for (int j = i + 1; j < n; j++) {         for (int si = 0; si < a[i].second.size(); si++) {           for (int sj = 0; sj < a[j].second.size(); sj++) {             long long old = b[j];             if (i > 0) {               old -= b[i - 1];             }             long long vLeft, vRight, vMiddle = 0;             vLeft = a[i].second.back();             if (si > 0) {               if (a[i].first ==  + ) {                 vLeft -= a[i].second[si - 1];               } else {                 vLeft /= a[i].second[si - 1];               }             }             vRight = a[j].second[sj];             if (j - 1 > i) {               vMiddle = b[j - 1] - b[i];             }             long long v = vLeft + vRight + vMiddle;             if (si > 0) {               if (a[i].first ==  + ) {                 v += a[i].second[si - 1];               } else {                 v *= a[i].second[si - 1];               }             }             if (sj < a[j].second.size() - 1) {               if (a[j].first ==  + ) {                 v += a[j].second.back() - a[j].second[sj];               } else {                 v *= a[j].second.back() / a[j].second[sj];               }             }             maxDiff = max(maxDiff, v - old);           }         }       }     }     cout << ans + maxDiff << endl;     return 0;   }   