Page 134 - Plus_V2.2_C7_Flipbook
P. 134
Program 5: To find out if the student is selected for the college or not based on the given
conditions
1. Selected if age > 18 and marks > 65.
2. Not selected if age > 18 and marks < 65.
3. Not selected if age < 18.
On running the program given on the previous page, we get the following output:
Program 6: To check if the given number is lucky or not, if the given number is greater than zero
and is even, then print ‘Lucky number’ else print ‘Not a lucky number’.
132 Premium Edition-VII

