Programming Code Examples

Eligible for vote program in C++ using function1 min read

In this tutorial we are writing a C++ Program to Check Eligibility for voting using function.

To check that a person is eligible for voting or not, we need to check whether person’s age is greater than or equal to 18. For this we are reading age in a variable a and checking the condition a>=18, if the condition is true, “person will be eligible for voting” else not.

Program Source Code : C++ program to check eligibility for voting using function


Add comment