Most viewed recipes tagged "program"http://code.activestate.com/recipes/tags/program/views/2016-04-13T11:53:21-07:00ActiveState Code RecipesSimple White Noise Generator Using Standard Python In Linux. (Python) 2011-03-10T18:03:55-08:00Barry Walkerhttp://code.activestate.com/recipes/users/4177147/http://code.activestate.com/recipes/577604-simple-white-noise-generator-using-standard-python/ <p style="color: grey"> Python recipe 577604 by <a href="/recipes/users/4177147/">Barry Walker</a> (<a href="/recipes/tags/audio/">audio</a>, <a href="/recipes/tags/demo/">demo</a>, <a href="/recipes/tags/generator/">generator</a>, <a href="/recipes/tags/linux/">linux</a>, <a href="/recipes/tags/noise/">noise</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/signal/">signal</a>, <a href="/recipes/tags/sound/">sound</a>, <a href="/recipes/tags/source/">source</a>). </p> <p>Simple White Noise Generator Using Standard Python In Linux - noise.py</p> <p>This code is a stand alone program to generate a signal, at the earphone sockets, of white noise.</p> <p>It needs /dev/dsp to work; if you haven't got it then install oss-compat from your distro's repository. (NOTE:- /dev/audio could also be used but I decided to use /dev/dsp to show that this was within easy reach of standard Python too.)</p> <p>Ensure the audio system is NOT in use for this to work and all the levels are set up for your normal requirements. In my case root level WAS NOT required but that does not mean that root level IS NOT required - so be aware.</p> <p>All that is required to make this a piece of audio test equipment is a cable plugged into to the earphone socket. The output level is fully controllable inside the code and the noise is generated in about 10 second bursts</p> <p>Assuming it is copied into the module(s) drawer just type:-</p> <pre class="prettyprint"><code>&gt;&gt;&gt; import noise[RETURN/ENTER] </code></pre> <p>And away you go...</p> <p>This is Public Domain and you may do with it as you like.</p> <p>Read the program for more information. (There will be more to come in the future... :)</p> <p>Enjoy finding simple solutions to often very difficult problems... ;o)</p> <p>73...</p> <p>Bazza, G0LCU...</p> <p>Team AMIGA...</p> Simple 1KHz Audio Function Generator Using Standard Python In Linux... (Python) 2011-03-01T19:37:16-08:00Barry Walkerhttp://code.activestate.com/recipes/users/4177147/http://code.activestate.com/recipes/577592-simple-1khz-audio-function-generator-using-standar/ <p style="color: grey"> Python recipe 577592 by <a href="/recipes/users/4177147/">Barry Walker</a> (<a href="/recipes/tags/audio/">audio</a>, <a href="/recipes/tags/demo/">demo</a>, <a href="/recipes/tags/function/">function</a>, <a href="/recipes/tags/generator/">generator</a>, <a href="/recipes/tags/linux/">linux</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/signal/">signal</a>, <a href="/recipes/tags/sound/">sound</a>, <a href="/recipes/tags/source/">source</a>). </p> <h5 id="simple-1khz-audio-function-generator-using-standard-python-in-linux-afgpy">Simple 1KHz Audio Function Generator Using Standard Python In Linux - afg.py</h5> <p>This code is a stand alone program to generate a signal, at the earphone sockets, of 1KHz. It is a basic audio signal generator and can be used as a starter test signal source for amateur electronics enthusiasts testgear suite(s).</p> <p>It needs /dev/audio to work; if you haven't got it then install oss-compat from your distro's repository.</p> <p>Ensure the audio system is NOT in use for this to work.</p> <p>Sine, Square, Triangle, Sawtooth+, Sawtooth-, Pulse+ and Pulse- signals are generated in 10 second bursts. The waveforms generated are unfiltered and therefore not "pure", but hey, an audio function generator signal source, for free, without external hardware, AND, using standard Python, what more do you want... :) An oscilloscope will show the waveforms generated at the earphone socket.</p> <p>Noise is not included but that is SO easy that I left it out FTTB. (This will be a future upload. ;o)</p> <p>All that is required to make this a piece of audio test equipment is a cable plugged into to the earphone socket.</p> <p>Assuming it is copied into the module(s) drawer just type:-</p> <pre class="prettyprint"><code>&gt;&gt;&gt; import afg[RETURN/ENTER] </code></pre> <p>And away you go...</p> <p>This is Public Domain and you may do with it as you like.</p> <p>Read the program for more information. (There will be more to come in the future... :)</p> Platform Independent 1KHz Pure Audio Sinewave Generator... (Python) 2012-10-23T12:53:37-07:00Barry Walkerhttp://code.activestate.com/recipes/users/4177147/http://code.activestate.com/recipes/578301-platform-independent-1khz-pure-audio-sinewave-gene/ <p style="color: grey"> Python recipe 578301 by <a href="/recipes/users/4177147/">Barry Walker</a> (<a href="/recipes/tags/apple/">apple</a>, <a href="/recipes/tags/audio/">audio</a>, <a href="/recipes/tags/demo/">demo</a>, <a href="/recipes/tags/generator/">generator</a>, <a href="/recipes/tags/linux/">linux</a>, <a href="/recipes/tags/macbook_pro/">macbook_pro</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/pyaudio/">pyaudio</a>, <a href="/recipes/tags/signal/">signal</a>, <a href="/recipes/tags/sinewave/">sinewave</a>, <a href="/recipes/tags/sound/">sound</a>, <a href="/recipes/tags/source/">source</a>, <a href="/recipes/tags/windows/">windows</a>). Revision 2. </p> <p>IKHz_SW_OSX.py</p> <p>A mono _pure_ sinewave generator using standard text mode Python 2.6.7 to at least 2.7.3.</p> <p>This DEMO kids level 1KHz generator is mainly for a MacBook Pro, (13 inch in my case), OSX 10.7.5 and above. See below...</p> <p>It is another simple piece of testgear for the young amateur electronics enthusiast and uses pyaudio fully installed for it to work.</p> <p>PyAudio can be obtained from here:- <a href="http://people.csail.mit.edu/hubert/pyaudio/" rel="nofollow">http://people.csail.mit.edu/hubert/pyaudio/</a></p> <p>This was primarily for a MacBook Pro, but works on at least 2 Linux flavours and Windows Vista 32 bit...</p> <p>The sinewave generated is near excellent...</p> <p>Enjoy finding simple solutions to often very difficult problems... Bazza, G0LCU...</p> Music Downloader (Python) 2013-05-25T06:52:51-07:00Christian Careagahttp://code.activestate.com/recipes/users/4186639/http://code.activestate.com/recipes/578530-music-downloader/ <p style="color: grey"> Python recipe 578530 by <a href="/recipes/users/4186639/">Christian Careaga</a> (<a href="/recipes/tags/download/">download</a>, <a href="/recipes/tags/downloader/">downloader</a>, <a href="/recipes/tags/music/">music</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/python/">python</a>, <a href="/recipes/tags/python_scripts/">python_scripts</a>, <a href="/recipes/tags/selenium/">selenium</a>, <a href="/recipes/tags/urllib/">urllib</a>, <a href="/recipes/tags/urllib2/">urllib2</a>). </p> <p>A Python Program i wrote that downloads music from the web</p> Morse Code (Python) 2012-01-12T23:45:12-08:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/578012-morse-code/ <p style="color: grey"> Python recipe 578012 by <a href="/recipes/users/2608421/">Stephen Chappell</a> (<a href="/recipes/tags/demo/">demo</a>, <a href="/recipes/tags/demonstration/">demonstration</a>, <a href="/recipes/tags/example/">example</a>, <a href="/recipes/tags/experiment/">experiment</a>, <a href="/recipes/tags/morse/">morse</a>, <a href="/recipes/tags/morse_code/">morse_code</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/sound/">sound</a>). Revision 3. </p> <p>After seeing another recipe recently that helps people with Morse Code, I was inspired to clean up the following code just a bit to make it worthy for the rest of the world. After being executed, it waits for lines of text to be entered, compiles each one in turn into timing codes, and plays them back with a simple execution</p> Platform Independent White Noise Generator... (Python) 2012-11-25T10:10:45-08:00Barry Walkerhttp://code.activestate.com/recipes/users/4177147/http://code.activestate.com/recipes/578350-platform-independent-white-noise-generator/ <p style="color: grey"> Python recipe 578350 by <a href="/recipes/users/4177147/">Barry Walker</a> (<a href="/recipes/tags/apple/">apple</a>, <a href="/recipes/tags/audio/">audio</a>, <a href="/recipes/tags/demo/">demo</a>, <a href="/recipes/tags/generator/">generator</a>, <a href="/recipes/tags/linux/">linux</a>, <a href="/recipes/tags/macbook_pro/">macbook_pro</a>, <a href="/recipes/tags/noise/">noise</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/pyaudio/">pyaudio</a>, <a href="/recipes/tags/signal/">signal</a>, <a href="/recipes/tags/sound/">sound</a>, <a href="/recipes/tags/source/">source</a>, <a href="/recipes/tags/windows/">windows</a>). </p> <p>This code is a derivative of the Pure Sinewave Generator and produces a continuous noise out of the speakers or headphone sockets.</p> <p>It is for the hobbyist to be able to generate a pseudo-random noise signal for testing with.</p> <p>It is issued as Public Domian and you may do with it as you please.</p> <p>It is very easy to convert to Python 3.x.x but as OSX only has 2.7.x and lower ATM then these are what are used...</p> <p>An installation of pyaudio IS needed for this to work; see the code for more information.</p> <p>It is near platform independent but sadly the AMIGA is not included, but hey, I have already shown how generate sound for Classic AMIGAs.</p> <p>Enjoy finding simple solutions to often very difficult problems...</p> <p>Bazza, G0LCU...</p> Quiz Me 2.5 (main) (Python) 2011-01-09T21:14:04-08:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/577525-quiz-me-25-main/ <p style="color: grey"> Python recipe 577525 by <a href="/recipes/users/2608421/">Stephen Chappell</a> (<a href="/recipes/tags/gui/">gui</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/python/">python</a>, <a href="/recipes/tags/quiz/">quiz</a>). Revision 2. </p> <p>Before discovering <a href="http://quizlet.com/" rel="nofollow">http://quizlet.com/</a>, the following program was developed for running custom quizzes to help with studying for college courses. The program is not very advanced, but it works reasonably well for what it was designed to do. If the program were developed further, it would need greater capabilities than it currently has and would require a secondary system for actually creating the quizzes (currently, they are hand-typed). Quiz Me could be a starting point for anyone who wishes to actually write a program such as this and inspire others to write much better programs than what this recipe currently offers.</p> <p>This is the main entry point to the Quiz Me program. It creates the GUI context and sets the program up for automatic error logging. Experimental threading support is provided but unused in the program. Since the main application subclasses a frame, it can easily be embedded in another application without much difficulty. Quiz Me is entirely event based and has an event runner in the very last method shown here.</p> Quiz Me 2.5 (XML example) (Python) 2011-01-11T00:51:24-08:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/577541-quiz-me-25-xml-example/ <p style="color: grey"> Python recipe 577541 by <a href="/recipes/users/2608421/">Stephen Chappell</a> (<a href="/recipes/tags/gui/">gui</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/python/">python</a>, <a href="/recipes/tags/quiz/">quiz</a>). Revision 2. </p> <p>Before discovering <a href="http://quizlet.com/" rel="nofollow">http://quizlet.com/</a>, the following program was developed for running custom quizzes to help with studying for college courses. The program is not very advanced, but it works reasonably well for what it was designed to do. If the program were developed further, it would need greater capabilities than it currently has and would require a secondary system for actually creating the quizzes (currently, they are hand-typed). Quiz Me could be a starting point for anyone who wishes to actually write a program such as this and inspire others to write much better programs than what this recipe currently offers.</p> <p>This is an example testbank file for Quiz Me. The questions and answers were created from a book used in a "HI 101" college class. What is presented here is a small sample of what would more likely be a much larger bank of question and answers used for automated quizzing or testing purposes. The XML shown here is formatted correctly dictated by an unwritten specification that the testbank (parsing) module requires. It is the quizcore module that takes the data through its final transformation and also builds questions and answers based on the material available. Once the .build() method has been called on classes inheriting from the _Category class, public attributes (QnA) become available on the _Category objects containing enough information for asking questions with provided answers. Fact objects also have .build() methods; once called, public Q2A and A2Q attributes can be used to find valid mappings of questions to answers and answers to questions.</p> How to build dobble as a Mixed Integer program. (Python) 2016-04-13T11:53:21-07:00alexander bakerhttp://code.activestate.com/recipes/users/4166679/http://code.activestate.com/recipes/580641-how-to-build-dobble-as-a-mixed-integer-program/ <p style="color: grey"> Python recipe 580641 by <a href="/recipes/users/4166679/">alexander baker</a> (<a href="/recipes/tags/integer/">integer</a>, <a href="/recipes/tags/interface/">interface</a>, <a href="/recipes/tags/mixed/">mixed</a>, <a href="/recipes/tags/program/">program</a>). </p> <p>A simple script to replicate the cards and symbols for the dobble game.</p> Kids Level Analogue Data Logger, (Transient Recorder), Program. (Python) 2011-07-31T16:14:48-07:00Barry Walkerhttp://code.activestate.com/recipes/users/4177147/http://code.activestate.com/recipes/577796-kids-level-analogue-data-logger-transient-recorder/ <p style="color: grey"> Python recipe 577796 by <a href="/recipes/users/4177147/">Barry Walker</a> (<a href="/recipes/tags/amiga/">amiga</a>, <a href="/recipes/tags/analogue/">analogue</a>, <a href="/recipes/tags/anim/">anim</a>, <a href="/recipes/tags/apple/">apple</a>, <a href="/recipes/tags/arduino/">arduino</a>, <a href="/recipes/tags/data/">data</a>, <a href="/recipes/tags/demo/">demo</a>, <a href="/recipes/tags/display/">display</a>, <a href="/recipes/tags/e_uae/">e_uae</a>, <a href="/recipes/tags/linux/">linux</a>, <a href="/recipes/tags/logger/">logger</a>, <a href="/recipes/tags/macbook_pro/">macbook_pro</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/windows/">windows</a>, <a href="/recipes/tags/winuae/">winuae</a>). Revision 2. </p> <p>This code is kids level Analogue Data-Logger(/Transient-Recorder), using the Arduino series of dev' boards.</p> <p>It is no where near completion and is a second feeder/feeler upload only.</p> <p>It is designed to work from Classic Text Mode Python from Versions 1.4.0 to 2.7.2 on a Classic AMIGA, WinUAE, Linux and Windows, (32 bit), to Vista. Not tested on Python for Windows 7, (32 bit), nor Mac OSX flavours as I don't have these OSes.</p> <p>Linux versions run from a default root terminal for the time being.</p> <p>The Arduino dev' board IS catered for in the code for the above platforms just thoroughly read the code for more information. It defaults to a DEMO mode so you can see it working...</p> <p>The test code for the Arduino Diecimila Dev Board is here:-</p> <p><a href="http://code.activestate.com/recipes/577625-arduino-diecimila-board-access-inside-winuae-demo/" rel="nofollow">http://code.activestate.com/recipes/577625-arduino-diecimila-board-access-inside-winuae-demo/</a></p> <p>Enjoy finding simple solutions to often very difficult problems... ;o)</p> <p>Bazza, G0LCU...</p> Reading Guide Generator (Python) 2009-01-01T10:38:15-08:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/576600-reading-guide-generator/ <p style="color: grey"> Python recipe 576600 by <a href="/recipes/users/2608421/">Stephen Chappell</a> (<a href="/recipes/tags/bible/">bible</a>, <a href="/recipes/tags/program/">program</a>). </p> <p>For those of you who have not found a Bible reading schedule or are not satisfied with what you have and want a change, the following recipe is provided as the result of a programming project today for the New Year. Begin with the first reference and read up to but not including the next reference. Continue from day to day, and you will find that by the end of the year, the entire Bible has been read with equally spaced portions of reading and time. The schedule was developed with the intention to read about the same number of words per day. The Bible used was "bible13.txt" (King James Version) from Project Gutenberg.</p> Quiz Me 2.5 (testbank) (Python) 2011-01-11T00:28:15-08:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/577531-quiz-me-25-testbank/ <p style="color: grey"> Python recipe 577531 by <a href="/recipes/users/2608421/">Stephen Chappell</a> (<a href="/recipes/tags/gui/">gui</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/python/">python</a>, <a href="/recipes/tags/quiz/">quiz</a>). </p> <p>Before discovering <a href="http://quizlet.com/" rel="nofollow">http://quizlet.com/</a>, the following program was developed for running custom quizzes to help with studying for college courses. The program is not very advanced, but it works reasonably well for what it was designed to do. If the program were developed further, it would need greater capabilities than it currently has and would require a secondary system for actually creating the quizzes (currently, they are hand-typed). Quiz Me could be a starting point for anyone who wishes to actually write a program such as this and inspire others to write much better programs than what this recipe currently offers.</p> <p>Quizes are stored as XML files and must be parsed and processed for use within the Quiz Me application. BankParser acts as a ContentHandler when used in parsing one of these XML files. It builds a tree of _Nodes, extracts attributes and textual data as needed, and validates the structure of the quiz bank data stream. _Nodes act as an abstract representation of XML elements and have the capability of reconstructing the relevant part of the XML that they encapsulate. Several classes follow that inherit from the _Node class and specify an attribute that node is expected to contain. The parse function takes a filename and returns a TestBank root object if parsing and validation were successful at this stage of a quiz's loading sequence.</p> Quiz Me 2.5 (quizcore) (Python) 2011-01-10T03:55:11-08:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/577528-quiz-me-25-quizcore/ <p style="color: grey"> Python recipe 577528 by <a href="/recipes/users/2608421/">Stephen Chappell</a> (<a href="/recipes/tags/gui/">gui</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/python/">python</a>, <a href="/recipes/tags/quiz/">quiz</a>). </p> <p>Before discovering <a href="http://quizlet.com/" rel="nofollow">http://quizlet.com/</a>, the following program was developed for running custom quizzes to help with studying for college courses. The program is not very advanced, but it works reasonably well for what it was designed to do. If the program were developed further, it would need greater capabilities than it currently has and would require a secondary system for actually creating the quizzes (currently, they are hand-typed). Quiz Me could be a starting point for anyone who wishes to actually write a program such as this and inspire others to write much better programs than what this recipe currently offers.</p> <p>The classes in this module take a XML node tree of a test/quiz bank and converts it into a definite, usable structure for creating a collection of question and answers that can be asked from different categories. UnitTest, Chapter, and Section represent divisions of a book (such as from history) and specify several different (inflexible) tiers in which questions may be placed. The Category function automatically determines what types of questions are being asked and creates appropriate objects that contain Fact objects from which Questions and Answers are generated. True_Or_False, Multiple_Choice, and Matching questions types are supported.</p> Quiz Me 2.5 (splash) (Python) 2011-01-10T04:05:50-08:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/577529-quiz-me-25-splash/ <p style="color: grey"> Python recipe 577529 by <a href="/recipes/users/2608421/">Stephen Chappell</a> (<a href="/recipes/tags/gui/">gui</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/python/">python</a>, <a href="/recipes/tags/quiz/">quiz</a>). </p> <p>Before discovering <a href="http://quizlet.com/" rel="nofollow">http://quizlet.com/</a>, the following program was developed for running custom quizzes to help with studying for college courses. The program is not very advanced, but it works reasonably well for what it was designed to do. If the program were developed further, it would need greater capabilities than it currently has and would require a secondary system for actually creating the quizzes (currently, they are hand-typed). Quiz Me could be a starting point for anyone who wishes to actually write a program such as this and inspire others to write much better programs than what this recipe currently offers.</p> <p>Splash provides an easy mechanism for displaying a splash screen as the "Quiz Me" program is starting up. This recipe has been published elsewhere on the Python Cookbook, but is included here for completeness in the layout of the program. The class's constructor takes the root of the application, the path to the logo to be displayed (usually a GIF image), and a minimum amount of time for the splash screen to be displayed. Used as a context manager around initialization code makes this a very easy class to use, and it will automatically clean up after itself when it has finished doing its job.</p> Quiz Me 2.5 (teach_me) (Python) 2011-01-10T13:45:13-08:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/577530-quiz-me-25-teach_me/ <p style="color: grey"> Python recipe 577530 by <a href="/recipes/users/2608421/">Stephen Chappell</a> (<a href="/recipes/tags/gui/">gui</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/python/">python</a>, <a href="/recipes/tags/quiz/">quiz</a>). </p> <p>Before discovering <a href="http://quizlet.com/" rel="nofollow">http://quizlet.com/</a>, the following program was developed for running custom quizzes to help with studying for college courses. The program is not very advanced, but it works reasonably well for what it was designed to do. If the program were developed further, it would need greater capabilities than it currently has and would require a secondary system for actually creating the quizzes (currently, they are hand-typed). Quiz Me could be a starting point for anyone who wishes to actually write a program such as this and inspire others to write much better programs than what this recipe currently offers.</p> <p>FAQ (Frequently Asked Questions) is used to generate events that power the quizzing process. The remaining classes represent the different event types. Enter and Exit instances are yielded when entering and exiting different tiers in the quiz structure. Reports are yielded after a tier has been completed and allow whoever is taking a test to review how well the questions have been answered per section, chapter, and complete quiz. Questions are randomly created and yielded and provide a way to easily answer from a list of choices. The Answer class extends the Question interface for getting more information when reviewing incorrectly answered questions.</p> Quiz Me 2.5 (gui_logs) (Python) 2011-01-10T03:43:42-08:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/577527-quiz-me-25-gui_logs/ <p style="color: grey"> Python recipe 577527 by <a href="/recipes/users/2608421/">Stephen Chappell</a> (<a href="/recipes/tags/gui/">gui</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/python/">python</a>, <a href="/recipes/tags/quiz/">quiz</a>). </p> <p>Before discovering <a href="http://quizlet.com/" rel="nofollow">http://quizlet.com/</a>, the following program was developed for running custom quizzes to help with studying for college courses. The program is not very advanced, but it works reasonably well for what it was designed to do. If the program were developed further, it would need greater capabilities than it currently has and would require a secondary system for actually creating the quizzes (currently, they are hand-typed). Quiz Me could be a starting point for anyone who wishes to actually write a program such as this and inspire others to write much better programs than what this recipe currently offers.</p> <p>There are several dialogs used throughout Quiz Me, and this module implements most of them. The standard dialog class in "tkinter.simpledialog" is modified slightly and used as a base class for the rest of the dialogs. ShowStatus displays whether a tier of the quiz is being entered or exited. AskQuestion allows questions to be asked and answered. ReviewProblems can be used to cycle through questions that were answered incorrectly. ShowReport gives a readout of the current cumulative progress score earned in the quiz. </p> Quiz Me 2.5 (exe_queue) (Python) 2011-01-09T21:19:15-08:00Stephen Chappellhttp://code.activestate.com/recipes/users/2608421/http://code.activestate.com/recipes/577526-quiz-me-25-exe_queue/ <p style="color: grey"> Python recipe 577526 by <a href="/recipes/users/2608421/">Stephen Chappell</a> (<a href="/recipes/tags/gui/">gui</a>, <a href="/recipes/tags/program/">program</a>, <a href="/recipes/tags/python/">python</a>, <a href="/recipes/tags/quiz/">quiz</a>). </p> <p>Before discovering <a href="http://quizlet.com/" rel="nofollow">http://quizlet.com/</a>, the following program was developed for running custom quizzes to help with studying for college courses. The program is not very advanced, but it works reasonably well for what it was designed to do. If the program were developed further, it would need greater capabilities than it currently has and would require a secondary system for actually creating the quizzes (currently, they are hand-typed). Quiz Me could be a starting point for anyone who wishes to actually write a program such as this and inspire others to write much better programs than what this recipe currently offers.</p> <p>The Pipe and _Method classes presented here are for providing optional thread support to the tkinter GUI library. Oftentimes, it can be inconvenient to play with threads and GUI libraries simultaneously, and most GUI libraries require GUI specific operations to be performed within a certain thread. The classes below are for wrapping the root of the application so that method calls can be executed at a later time within whatever thread they are supposed to be executed in. This program was used as a test platform of the concept though it did not see any of its expected use: threading is not used in this application.</p>