Skip to content

student grading algorithm #8894

@fawwazwasique

Description

@fawwazwasique

What would you like to share?

def calculate_grade(score):
    if 90 <= score <= 100:
        return "A"
    elif 80 <= score < 90:
        return "B"
    elif 70 <= score < 80:
        return "C"
    elif 60 <= score < 70:
        return "D"
    else:
        return "F"

def main():
    num_students = int(input("Enter the number of students: "))

    student_data = {}  # Dictionary to store student names and scores

    for i in range(num_students):

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    awaiting triageAwaiting triage from a maintainer

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions