#include <bits/stdc++.h>   using namespace std;   long long qpow(long long a, long long k) {     long long b = 1LL;     while (k) {       if (k % 2 == 1) b = (b * a) % 1000000007;       a = (a * a) % 1000000007;       k = k / 2;     }     return b;   }   int main() {     char s[105] = {0};     scanf( %s , s);     int len = strlen(s);     long long ans = 0;     for (int i = len - 1; i >= 0; i--) {       ans = ans * 2;       ans = ans % 1000000007;       if (s[i] ==  1 ) {         ans = ans + qpow(4LL, (long long)(len - 1 - i));         ans = ans % 1000000007;       }     }     printf( %I64d , ans);     return 0;   }   