title: Simple Test from Python Dictionary
body: <p>I took a step back from programming, and forgot nearly everything I ever learned (not that it was much, anyhow). I wanted to refresh, with something relatively simple, so I've been trying to create a practice test that I plan on expanding into flash cards with Tkinter. It's a study aid for my CDC's in the Air Force, so I won't post the actual contents of my dictionary, but here's the code (I got it from YouTube). I want to be able to remove (pop?) correct answers from the dictionary, so they don't come up anymore, and keep the wrong answers in the loop of questions. I'd also like to add in something to monitor the sections that I need to brush up on. Currently it just loops through all of the questions and then displays the amount of correct/wrong. It works, but it's not as effective as I'd like to to be. I've been searching for ways to do this but I can't seem to find a concrete answer and I had success with a post here in the past, so I figured I'd give it a shot. You guys are impressive, and I appreciate any responses and feedback I can get. I have  63 questions so my code is really long, and I was thinking it would be better to put my dictionary into a separate file and just import that file?</p>
  
  <p>The numbers indicate the section it is pertaining to. I want to be able to grab the numbers (002) of all the wrong answers, and print them after I print # of correct/wrong answers. So it would say 10 correct, 20 wrong, 5 from section 002, 15 from section 3, or whatever.</p>
  
  <pre><code>import random
  try: input = raw_input
  except: pass 
  
  mydict = {
  '(001) Insert Question Here' : ['Answer A Text', 'Answer B Text', 'Answer C Text', 'Answer D Text', 0],
  '(001) Insert Question Here' : ['Answer A Text', 'Answer B Text', 'Answer C Text', 'Answer D Text', 3],
  '(002) Insert Question Here' : ['Answer A Text', 'Answer B Text', 'Answer C Text', 'Answer D Text', 2],
  '(002) Insert Question Here' : ['Answer A Text', 'Answer B Text', 'Answer C Text', 'Answer D Text', 0]
  }
  
  keyword_list = list(mydict.keys())
  random.shuffle(keyword_list)
  print('Pick the correct answer: ')
  correct = 0
  wrong = 0
  buffer = '-'*30
  next_question = "Next Question: "
  
  for keyword in keyword_list:
      sf = '''
  {}
  A) {}
  B) {}
  C) {}
  D) {}
  '''
      print(sf.format(keyword, mydict[keyword][0],
                      mydict[keyword][1], mydict[keyword][2], mydict[keyword][3]))
      letter = input("Enter Letter Of Your Choice (A, B, C, D): ").upper()
      if letter == "ABCD"[mydict[keyword][4]]:
          correct += 1
          print('Correct! Great Job!')
          print(buffer)
          print(next_question)
  
      else:
          wrong += 1
          print('Wrong :(')
          print('The correct answer was ' + 'ABCD'[mydict[keyword][4]])
          print(buffer)
          print(next_question)
  
  sf = "Answers given ---&gt; {} correct and {} wrong"
  print(sf.format(correct, wrong))
  </code></pre>