Need help converting my pseudocode to python, AND have a flowchart showing everything!The code: Function getScore() // Prompt the user to enter a test score Display "Enter a test score as a percentage (0-100): " Input score // Return the score entered by the user Return scoreEnd Function Function getGPAPoint(Integer score) // Determine GPA point based on the score If score >= 90 Then Return 4.0 Else If score >= 80 Then Return 3.0 Else If score >= 70 Then Return 2.0 Else If score >= 60 Then Return 1.0 Else Return 0.0 End IfEnd Function Function getAverage() // Initialize variables to store the sum of scores and GPA points totalScore = 0 totalGPA = 0.0 // Loop to collect 5 test scores For i = 1 to 5 Do score = getScore() // Call getScore function to get a test score totalScore = totalScore + score // Add score to totalScore gpaPoint = getGPAPoint(score) // Convert the score to GPA point totalGPA = totalGPA + gpaPoint // Add GPA point to totalGPA End For // Calculate average score and average GPA averageScore = totalScore / 5 averageGPA = totalGPA / 5 // Display the results Display "Average Score: ", averageScore Display "Average GPA: ", averageGPAEnd Function Module Main // Call the getAverage function to calculate and display the results getAverage()End Module Link from previous:https://www.bartleby.com/questions-and-answers/i-need-help-writing-pseudocode-for-calculating-class-score-average-by-putting-in-5-test-scores-and-s/2a0a2372-1e1a-409d-8b0d-6b5572d6afde
Need help converting my pseudocode to python, AND have a flowchart showing everything!
The code:
Function getScore()
// Prompt the user to enter a test score
Display "Enter a test score as a percentage (0-100): "
Input score
// Return the score entered by the user
Return score
End Function
Function getGPAPoint(Integer score)
// Determine GPA point based on the score
If score >= 90 Then
Return 4.0
Else If score >= 80 Then
Return 3.0
Else If score >= 70 Then
Return 2.0
Else If score >= 60 Then
Return 1.0
Else
Return 0.0
End If
End Function
Function getAverage()
// Initialize variables to store the sum of scores and GPA points
totalScore = 0
totalGPA = 0.0
// Loop to collect 5 test scores
For i = 1 to 5 Do
score = getScore() // Call getScore function to get a test score
totalScore = totalScore + score // Add score to totalScore
gpaPoint = getGPAPoint(score) // Convert the score to GPA point
totalGPA = totalGPA + gpaPoint // Add GPA point to totalGPA
End For
// Calculate average score and average GPA
averageScore = totalScore / 5
averageGPA = totalGPA / 5
// Display the results
Display "Average Score: ", averageScore
Display "Average GPA: ", averageGPA
End Function
Module Main
// Call the getAverage function to calculate and display the results
getAverage()
End Module
Link from previous:
https://www.bartleby.com/questions-and-answers/i-need-help-writing-pseudocode-for-calculating-class-score-average-by-putting-in-5-test-scores-and-s/2a0a2372-1e1a-409d-8b0d-6b5572d6afde

Step by step
Solved in 2 steps with 1 images








