Skip to content

Instantly share code, notes, and snippets.

View CibelePaulinoAndrade's full-sized avatar
🎯
Focusing

Cibele Paulino Andrade CibelePaulinoAndrade

🎯
Focusing
View GitHub Profile
@CibelePaulinoAndrade
CibelePaulinoAndrade / Arvore B
Last active July 17, 2017 12:27
3ª Contribuição de Pesquisa
class No:
def __init__(self, folha=False):
self.chave = []
self.filho = []
self.folha = folha
def __str__(self):
if self.folha:
return "Noh folha da arvore com {0} chave\n\tChave:{1}\n\tfilho:{2}\n".format(len(self.chave), self.chave, self.filho)
else:
@CibelePaulinoAndrade
CibelePaulinoAndrade / Árvore AVL
Created July 13, 2017 20:44
2ª Contribuição de Pesquisa
from tkinter import *
import math
class NoArv:
def __init__(self, dado):
self.setFilhos(None, None)
self.dado = dado
def setFilhos(self, esquerdo, direito):
self.esquerdo = esquerdo
import random
import timeit
import matplotlib.pyplot as plt
tempLinear = []; tempBinaria = []; tempDifer = []; tempMedLinear = []; tempMedBinaria = []
tam=[6000, 9000, 12000, 15000, 24000]
def listaRan(tam, lista):
random.seed()
i=0;
import random
import timeit
import matplotlib.pyplot as plt
b=[]; s=[]; c=[]; q=[]; m=[]; l=[]; t=[]; r=[]; k=[]; h=[]
listaAuxB=[]; listaAuxS=[]; listaAuxI=[]; listaAuxQ=[]; listaAuxM=[]; listaAuxL=[]; listaAuxT=[]; listaAuxR=[]; listaAuxBt=[]; listaAuxH=[]
listaaux=[]
tam=[100, 300, 600, 900, 1200, 2400, 4800, 7000]
tipo=[1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
import random
import timeit
import matplotlib.pyplot as plt
b=[]; s=[]; c=[]; q=[]; m=[]; l=[]; t=[]; r=[]; k=[]
listaAuxB=[]; listaAuxS=[]; listaAuxI=[]; listaAuxQ=[]; listaAuxM=[]; listaAuxL=[]; listaAuxT=[]; listaAuxR=[]; listaAuxB=[]
listaaux=[]
tam=[100, 300, 600, 900, 1200, 2400, 4800, 7000]
tipo=[1, 2, 3, 4, 5, 6, 7, 8, 9]
@CibelePaulinoAndrade
CibelePaulinoAndrade / Radix Sort
Created June 9, 2017 17:48
Pesquisa e Ordenação
import random
import timeit
import matplotlib.pyplot as plt
b=[]; s=[]; c=[]; q=[]; m=[]; l=[]; t=[]; r=[]
listaAuxB=[]; listaAuxS=[]; listaAuxI=[]; listaAuxQ=[]; listaAuxM=[]; listaAuxL=[]; listaAuxT=[]; listaAuxR=[]
listaaux=[]
tam=[100, 300, 600, 900, 1200, 2400, 4800, 7000]
tipo=[1, 2, 3, 4, 5, 6, 7, 8]
import random
import timeit
import matplotlib.pyplot as plt
b=[]; s=[]; c=[]; q=[]; m=[]; l=[]; t=[]
listaAuxB=[]; listaAuxS=[]; listaAuxI=[]; listaAuxQ=[]; listaAuxM=[]; listaAuxL=[]; listaAuxT=[]
listaaux=[]
tam=[100, 300, 600, 900, 1200, 2400, 4800, 7000]
tipo=[1, 2, 3, 4, 5, 6, 7]
import random
import timeit
import matplotlib.pyplot as plt
b=[]; s=[]; c=[]; q=[]; m=[]; l=[]
listaAuxB=[]; listaAuxS=[]; listaAuxI=[]; listaAuxQ=[]; listaAuxM=[]; listaAuxL=[]
tam=[100, 300, 600, 900, 1200, 2400, 4800, 10000]
tipo=[1, 2, 3, 4, 5, 6]
def bubbleSort(lista):
#Bubble Sort x Selection Sort x Insertion Sort x Quick Sort x Merge Sort
import random
import timeit
import matplotlib.pyplot as plt
b=[]; s=[]; c=[]; q=[]; m=[]
listaAuxB=[]; listaAuxS=[]; listaAuxI=[]; listaAuxQ=[]; listaAuxM=[]
tam=[100, 300, 600, 900, 1200, 2400, 4800, 10000]
tipo=[1, 2, 3, 4, 5]