CHAPTER 88 •
PYTHON
Python Mini Project
Build a small console-based student result program.
01 What is this?
Build a small console-based student result program.
02 Syntax
Python Syntax
program = input + logic + output
03 Example
Python Example
name = input('Student Name: ')
marks = int(input('Marks: '))
if marks >= 90:
grade = 'A+'
elif marks >= 80:
grade = 'A'
elif marks >= 60:
grade = 'B'
elif marks >= 40:
grade = 'C'
else:
grade = 'F'
print(name, grade)
04 Important Points
Projects help connect individual concepts.
05 Common Mistakes
Break large problems into smaller functions and steps.
06 Real World Use
The same approach is used when developing real software.
07 Practice This Topic
Now try the example yourself in the AIFA Python Editor.
- Read the example carefully.
- Change the values.
- Run the code.
- Observe the output.
- Try creating your own example.