Олимпиадный тренинг

Задача 38698. Odd to even


Given an array of N integers. Write a program that outputs the odd elements of an array (that is, those elements that are odd numbers) that have even indices (element numbering starts at 0).

Input
First given number N — the number of elements in the array (1<=N<=100). Then, space-separated N numbers — array elements. The array consists of integers, modulo not exceeding 100.
 
Output
It is necessary to display all odd elements of the array that have even indices.
 
 
Examples
# Input Output
1 5
1 1 3 4 6
1 3