A collection of simple turtle code examples Type them in and try them out Code # draw star using Turtle import turtle board = turtle.Turtle() for i in range(6): board.forward(50) …
Python
-
In this code example we show you how to use a dictionary to create a simple quiz, then you can loop through the questions and try and answer them This …
-
In this article we look at the tKinter button These buttons are able to display text or images that convey the purpose of the buttons. You can attach a function …
-
The statistics module provides functions to mathematical statistics of numeric data. there are a variety of useful functions are available The statistics module was introduced in Python 3.4, so if …
-
In this article we look at python and wmi, first what exactly is wmi. Windows Management Instrumentation (WMI) consists of a set of extensions to the Windows Driver Model that provides an operating system interface …
-
A selection sort is an in-place comparison sorting algorithm. It has an O(n2) time complexity, which makes it inefficient on large lists, and generally performs worse than the similar insertion sort. Selection sort is noted for its …
-
A bubble sort, sometimes referred to as sinking sort, is a simple sorting algorithm that repeatedly steps through the list, compares adjacent elements and swaps them if they are in …
In this article we use Pyscreenshot to take a screenshot using python Pyscreenshot tries to allow to take screenshots without installing 3rd party libraries. It is cross-platform. It is only …
Quicksort is an in-place sorting algorithm it is still a commonly used algorithm for sorting. When implemented well, it can be somewhat faster than merge sort and about two or three times faster than heapsort. Quicksort …