Google Drive Logo Using Python Turtle

import turtle as t

t.hideturtle()

t.Screen().bgcolor("Black")

t.pencolor("white")

t.pensize(0)

t.begin_fill()

t.fillcolor('#4688F4')

t.forward(170)

t.left(60)

t.forward(50)

t.left(120)

t.forward(220)

t.left(120)

t.forward(50)

t.end_fill()

t.begin_fill()

t.fillcolor('#1FA463')

t.left(120)

t.forward(200)

t.left(120)

t.forward(50)

t.left(60)

t.forward(150)

t.left(60)

t.forward(50)

t.end_fill()

t.penup()

t.left(120)

t.forward(200)

t.left(120)

t.forward(50)

t.pendown()

t.begin_fill()

t.fillcolor('#FFD048')

t.left(125)

t.forward(160)

t.left(55)

t.forward(53)

t.left(126)

t.forward(163)

t.end_fill()

t.done()


Program to generate CAPTCHA and verify user

import random

def checkCaptcha(captcha, user_captcha):

if captcha == user_captcha:

return True

return False

def generateCaptcha(n):

chrs = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"

captcha = ""

while (n):

captcha += chrs[random.randint(1, 1000) % 62]

n -= 1

return captcha

captcha = generateCaptcha(9)

print(captcha)

print("Enter above CAPTCHA:")

usr_captcha = input()

if (checkCaptcha(captcha, usr_captcha)):

print("CAPTCHA Matched")

else:

print("CAPTCHA Not Matched")