#include <bits/stdc++.h>


int main(){
  std::cin.tie(0);
  std::ios::sync_with_stdio(false);

  double p;
  while(std::cin >> p){
    double ans = 0;

    ans = 1.0 / (1.0 - p) / (1.0 - p) * p * (1.0 - p);
    
    
    std::cout << std::fixed << std::setprecision(12) << ans << "\n";
  }

  return 0;
}