Sharp Tutorial
turtle in Python

Python

Java

C

C++

HTML/CSS

Java Script

PHP

SQL

C Programs

Introduction to Python

  • Introduction to Python
  • History of Python
  • How To Install Software
  • Variables in Python
  • Comments in Python
  • Input/Output
  • If else in Python
  • While Loop
  • For Loop

Collection in Python

  • Numbers in Python
  • List
  • Tuple
  • Set
  • Dictionary
  • Array
  • String

Object Oriented python

  • Function
  • Exception
  • OOPS (class/object)
  • Object Pass & Return
  • Constructor
  • Function Overloading
  • Module in Python
  • Inheritance
  • File Handling

Python With MYSQL And Excel

  • Connect MySql & Python
  • Insert Data MySQL
  • Delete/Update MySQL
  • Select Data From MySQL
  • Working With Excel in Python

Python GUI

  • GUI using Turtle
  • Introduction to Tkinter
  • Login Page using Tkinter
  • Data Grid Example Tkinter
  • Connect Multiple Forms
  • Database with GUI Python

Programs in Python

  • Swap two number
  • Calculate the area
  • Even Odd or Zero
  • Largest ,Middle and Smallest Number
  • Calculate Telephone Bill
  • Print Table of The given Number
  • Factorial of the number
  • Reverse and check number is palindrome
  • check number is prime , armstrong
  • Program to Print the given patterns
  • Guess A Number Game using Random

Turtle in Python

Watch Video Solution

Turtle may be used to draw GUI window. For this we have to import turtle module. Using turtle different object shape can be drawn. Code to draw Graphics GUI window as follows.

 

import turtle
my_wn = turtle.Screen()
turtle.exitonclick()

By using following code we can create multiple circles that forms the below shape as in the  given diagram

 

import turtle
my_wn = turtle.Screen()
turtle.speed(1)
for i in range (30):
	turtle.circle(5*i)
	turtle.circle(-5*i)
	turtle.left(i)
turtle.exitonclick()
import turtle
wn = turtle.Screen()
wn.bgcolor("light green")
wn.title("Turtle")
shape = turtle.Turtle()
shape.color("blue")

def drawShape(size):
    for i in range(4):
        shape.fd(size)
        shape.left(90)
        size = size-5

for i in range(150,20,-20):
 drawShape(i)

turtle.exitonclick()
import turtle
colors = ['red', 'purple', 'blue', 'green', 'orange', 'yellow']
t = turtle.Pen()
turtle.bgcolor('black')
for x in range(360):
    t.pencolor(colors[x%6])
    t.width(x/100 + 1)
    t.forward(x)
    t.left(59) 

turtle.left(180)
turtle.circle(5*2)

turtle.exitonclick()

Enquiry about Course

Ask your Question

Click Here

Sharp (2) Tutorials

Video/ C Introduction

Watch video in full size

Video tutorial

Follow by Email
Facebook
Facebook
fb-share-icon
YouTube
Copyright © Sharp Tutorial
Build with WordPress
Wordpress Social Share Plugin powered by Ultimatelysocial
Sharp Tutorial