#include <stdio.h>   // for printf, scanf

int count_odds(int A, int B)
{
  int counter = 0;
  int i;
  for (i = A; i <= B; i++)
  {
    if (i % 2 == 1)
    {
      counter++;
    }
  }

  return counter;
}


int main()
{
  int a, b;
  printf("please enter two integers A and B:\n");
  scanf("%d %d", &a, &b);

  if (a > b)
  {
    return 0;
  }

  int result = count_odds(a, b);
  printf("there are %d odd numbers between %d and %d\n", result, a, b);
}

