7. Python program to print the elements of an array present on even position
In this program, we need to print the element which is present on even position. Even positioned element can be found by traversing the array and incrementing the value of i by 2.
In the above array, elements on even position are b and d.
Elements of given array present on even position: 2 4
JavaTpoint offers too many high quality services. Mail us on [email protected], to get more information about given services.
JavaTpoint offers college campus training on Core Java, Advance Java, .Net, Android, Hadoop, PHP, Web Technology and Python. Please mail your requirement at [email protected]
Duration: 1 week to 2 week