#include using namespace std; int main() { string v; int t, ans; cin >> v >> t; v = v.substr(2, 4); ans = stoi(v)*t/10000; cout << ans << endl; return 0; }