title: Loading multiple variables in Python 3 using Pickle
body: <p>I recently started with Tkinter and thought it would be fun to create a stats sheet for a board game my friend made. However whenever I try to load the stats, they are all one stat, for example if all but one was 4, then when I loaded it, they were all 4. Can someone please explain it or help me fix it?</p>
  
  <p>Here is my code.</p>
  
  <pre><code>from tkinter import *
  import pickle
  
  ##############################################
  global P
  global I
  global R
  global A
  global T
  global E
  P = pickle.load(open("stats.p", "rb"))
  root = Tk()
  I = pickle.load(open("stats.p", "rb"))
  root = Tk()
  R = pickle.load(open("stats.p", "rb"))
  root = Tk()
  A = pickle.load(open("stats.p", "rb"))
  root = Tk()
  T = pickle.load(open("stats.p", "rb"))
  root = Tk()
  E = pickle.load(open("stats.p", "rb"))
  root = Tk()
  
  
  root=Tk()
  def addOneP():
  global P
  P += 1
  LP.config(text=P)
  
  
  def addOneI():
  global I
  I += 1
  LI.config(text=I)
  
  
  def addOneR():
  global R
  R += 1
  LR.config(text=R)
  
  
  def addOneA():
  global A
  A += 1
  LA.config(text=A)
  
  
  def addOneT():
  global T
  T += 1
  LT.config(text=T)
  
  
  def addOneE():
  global E
  E += 1
  LE.config(text=E)
  
  
  
  def save():
      pickle.dump(P, open("stats.p", "wb"))
      pickle.dump(I, open("stats.p", "wb"))
      pickle.dump(R, open("stats.p", "wb"))
      pickle.dump(A, open("stats.p", "wb"))
      pickle.dump(T, open("stats.p", "wb"))
      pickle.dump(E, open("stats.p", "wb"))
  
  
  
  ##############################################
  
  def reset():
      P=0
      I=0
      R=0
      A=0
      T=0
      E=0
  
  ##############################################
  
  root.title("Character Sheet")
  root.geometry("720x825")
  
  ##############################################
  
  LP = Label(root, text=P)
  LI = Label(root, text=I)
  LR = Label(root, text=R)
  LA = Label(root, text=A)
  LT = Label(root, text=T)
  LE = Label(root, text=E)
  
  T1 = Label(root, text="Persuasion : ")
  T2 = Label(root, text="Intelligence : ")
  T3 = Label(root, text="Rampart : ")
  T4 = Label(root, text="Accuracy : ")
  T5 = Label(root, text="Thrash : ")
  T6 = Label(root, text="Enchantment : ")
  
  B1 = Button(root, text="+", command=addOneP)
  B2 = Button(root, text="+", command=addOneI)
  B3 = Button(root, text="+", command=addOneR)
  B4 = Button(root, text="+", command=addOneA)
  B5 = Button(root, text="+", command=addOneT)
  B6 = Button(root, text="+", command=addOneE)
  
  RESET = Button(root, text="RESET", command=reset)
  
  SAVE = Button(root, text="SAVE", command=save)
  
  ##############################################
  
  T1.grid(column=2, row=3)
  T2.grid(column=2, row=5)
  T3.grid(column=2, row=7)
  T4.grid(column=2, row=9)
  T5.grid(column=2, row=11)
  T6.grid(column=2, row=13)
  
  LP.grid(column=6, row=3) 
  LI.grid(column=6, row=5)
  LR.grid(column=6, row=7)
  LA.grid(column=6, row=9)
  LT .grid(column=6, row=11)
  LE.grid(column=6, row=13)
  
  B1.grid(column=10, row=3)
  B2.grid(column=10, row=5)
  B3.grid(column=10, row=7)
  B4.grid(column=10, row=9)
  B5.grid(column=10, row=11)
  B6.grid(column=10, row=13)
  
  RESET.grid(column=10, row=20)
  
  SAVE.grid(column=5, row=20)
  ##############################################
  
  root.mainloop()
  </code></pre>