Coder Social home page Coder Social logo

sorting-algorithm-visualiser's Introduction

Sort Visualizer

Description:

Sort Visualizer is a Python GUI application made with Tkinter that allows users to visualize various sorting algorithms in action. Users can select from a variety of sorting algorithms such as Merge Sort, Bubble Sort, Insertion Sort, Selection Sort, and Quick Sort. They can also adjust parameters like sleep time (delay between each step of the sorting algorithm) and input array size. The application provides a visual representation of the sorting process, making it easier for users to understand and analyze how different sorting algorithms work.

Features:

  1. Selection of Sorting Algorithms: Users can choose from a dropdown menu of sorting algorithms to visualize. Supported algorithms include Merge Sort, Bubble Sort, Insertion Sort, Selection Sort, and Quick Sort.

  2. Adjustable Parameters: Users can adjust parameters like sleep time to control the speed of the sorting visualization. They can also specify the size of the input array to be sorted.

  3. Real-time Visualization: The application provides a real-time visual representation of the sorting process. As the sorting algorithm progresses, bars representing elements in the array are updated on the canvas, allowing users to see how the data is being sorted step by step.

  4. Random Data Generation: Users can generate random data of specified size to be used as input for sorting algorithms. This feature allows users to test and observe the behavior of sorting algorithms with different datasets.

Usage:

  1. Run the main script main.py:

    python main.py
    
  2. The Sort Visualizer GUI will appear. Select a sorting algorithm from the dropdown menu, adjust parameters as needed, and click the "Generate Data" button to generate random data.

  3. Click the "Visualize Sort" button to start visualizing the selected sorting algorithm with the generated data.

  4. Observe the sorting process in real-time on the canvas. You can adjust the speed of visualization and generate new data to explore different scenarios.

Credits:

Sort Visualizer uses the following libraries and resources:

  • Tkinter: Python's standard GUI (Graphical User Interface) toolkit.
  • Random: Python's built-in module for generating random numbers.
  • Sorting algorithms implementations: All but quicksort were from memory.
  • Justin Johnson's site for inspiration.

sorting-algorithm-visualiser's People

Contributors

gijimagarikai avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.