title: Python program to calculate student grades
body: <p>This is my first program in Python and I am having some trouble so forgive me if I have some simply syntax issues.</p>
  
  <p>I am writing a program that calculates a student's final score based on one exam grade worth 60% and 7 other test scores worth a combined 40% of the final grade. The user is asked to input the one exam score then asked to input the 7 test scores which are read in a loop. The letter grade is then determined from the final score calculated from the exam and tests. After that a grade comment is printed corresponding to the letter grade given to the student. This is my code so far:</p>
  
  <pre><code>def read_test_scores() :
  
      print("ENTER STUDENT ID: ")
      id = int(input())
  
      print("ENTER EXAM SCORE: ")
      exam = int(input())
  
      print("ENTER ALL TEST SCORES: ")
      score1 = int(input())
      score2 = int(input())
      score3 = int(input())
      score4 = int(input())
      score5 = int(input())
      score6 = int(input())
      score7 = int(input())
  
      sum = (score1 + score2 + score3 + score4 + score5 + score6 + score7)
  
      tavge = sum/7
      return tavge
  
  def compute_final_score(tavge, exam) :
      final_score = 0.4 * tavge + 0.6 * exam
      return final_score
  
  def get_letter_grade(final_score) :
  
      if 90 &lt;= final_score &lt;= 100:
          grade = 'A'
      elif 80 &lt;= final_score &lt;= 89:
          grade = 'B'
      elif 70 &lt;= final_score &lt;= 79:
          grade = 'C'
      elif 60 &lt;= final_score &lt;= 69:
          grade = 'D'
      else:
          grade = 'F'
      return grade
  
  def print_comment(grade) :
  
      if grade = 'A':
          print "COMMENT:            Very Good"
      elif grade = 'B':
          print "COMMENT:            Good"
      elif grade = 'C':
          print "COMMENT:            Satisfactory"
      elif grade = 'D':
          print "COMMENT:            Need Improvement"
      elif grade = 'F'
          print "COMMENT:            Poor"
  
  read_test_scores()
  print "TEST AVERAGE IS:    " + str(tavge)
  compute_final_score()
  print "FINAL SCORE IS:     " + str(final_score)
  get_letter_grade(final_score)
  print "LETTER GRADE IS:     " + str(grade)
  print_comment(grade)
  </code></pre>