Problem Analysis:
Observation: We can use condition to check 3 different cases and print output according to the case.
Solution Idea: You just need to take an integer which is the age and then check these 3 different cases:-
If (age<21) print “Sorry, you are too young to vote.”
else If (21<=age<23) print “Wait a little more to vote.”
else If (age>=23) print “Yes, you can vote.”