C++
#include <iostream>
using namespace std;
int main()
{
int x, y; cin >> x >> y;
if (x > y) swap(x, y);
int res = 0;
for (int i = x+1; i < y; i ++)
{
if (i % 2 != 0) res += i;
}
cout << res << endl;
return 0;
}
Python3
x = int(input())
y = int(input())
res = 0
if x > y:
x, y = y, x
for i in range(x+1, y):
if abs(i) % 2 != 0:
res += i
print(res)