#include #include using namespace std; using namespace atcoder; using ll = long long; using ld = long double; int a, b, N = 1000000; double sum, pos; int main() { cin >> a >> b; for (int i = 0; i < N; i++) { pos = (double)a + (double)(b - a) / N * i; sum += abs((pos - a) * (pos - b)) * (double)(b - a) / N; } cout << fixed << setprecision(15) << sum << endl; return 0; }