title: str AttributeError: 'str' object has no attribute 'set' (updating label)
body: <p>This is a simple math game. The function of interest is <code>checkAnswer()</code>. I am trying to update <code>label1</code> so that the label updates with the new str instead of continuously printing multiple labels.</p>
  
  <p>Error:</p>
  
  <blockquote>
    <p>AttributeError: 'str' object has no attribute 'set'</p>
  </blockquote>
  
  <pre><code>from tkinter import *
  
  from random import randint
  
  num1 = 0
  num2 = 0
  userAnswer = 0
  answer = 0
  score = 0
  labeltext = ""
  
  #PROGRAM FUNCTIONS
  def question():
      global num1, num2
      global answer
      num1 = randint(1,10)
      num2 = randint(1,10)
      question = Label(text = "What is " + str(num1)+ " + " + str(num2) + "?").pack()
      answer = num1+num2
      print(answer) #testing purposes
  
  def userAnswer():
      global userAnswer
      userAnswer = IntVar()
      entry = Entry(root, textvariable = userAnswer).pack()
      submit = Button(root, text = "submit", command = checkAnswer).pack()
  
  def checkAnswer():
      global labeltext
      print(userAnswer.get())
      if userAnswer == answer:
          labeltext.set("good job")
          score += 1
      elif userAnswer != answer:
          labeltext.set("oh no")
      labeltext = StringVar()
      label1 = Label(root, textvariable = labeltext).pack()
  
  #INTERFACE CODE
  root = Tk()
  
  question()
  userAnswer()
  root.mainloop()
  </code></pre>