This repository contains a collection of simple Python programs designed to demonstrate basic programming concepts. Each program focuses on a specific task or algorithm, providing a practical example of how to implement it in Python.
- If the score is less than or equal to 40, the grade is D.
- If the score is less than 61, the grade is C.
- If the score is less than 81, the grade is B.
- Otherwise, the grade is A.
- Output: "Your score is 50"
- Output: "Sorry, you did not pass"
- Display odd numbers from 1 to 100.
- Function to calculate the area of a triangle with parameters:
- Base
- Height
- Display the number of characters in a string.
- Input string: "Programmer"
- Calculate the area of a triangle.
- Function to calculate the area of a rectangle with parameters:
- Length
- Width
- Calculate the area of a circle with:
- π = 3.14
- Radius = 7
- Display even numbers from 1 to 75.
- Create an array containing the names of the days from Monday to Sunday.
- Example:
- Day 1 is Monday
- Day 2 is Tuesday
- Display the first 5 Fibonacci numbers with:
- First term = 6
- Second term = 9
- Create a right-angled triangle using stars.
- Create a full triangle using stars.
- Implement a basic calculator.
- Calculate the area of a rectangle.
- Calculate the area of a rectangle.
- Calculate sine, cosine, and tangent angles.
- Calculate density.
- Count from 1 to 1,000,000 and display the record.
- Calculate the surface area of a cube.
- Display odd numbers from 1 to 75.
Powered by Reza