This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# V 0.0.3 | |
# 2021-05-05 | |
# Shell script to create a very simple Django Ninja project. | |
# This script require Python 3.x and pyenv | |
# Settings.py is config to Django 3.1.5 and Django Ninja 0.12.1 | |
# The project contains: | |
# Settings config | |
# Admin config |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def solver(lista_entrada, int_a, int_b): | |
# Variáveis auxiliares que serão usadas nas iterações | |
contador_strings = 0 | |
repeticoes_de_a = 0 | |
repeticoes_de_b = 0 | |
# Início do 1º while | |
# len(lista_entrada) é a quantidade de elementos que possui a lista de strings e o contador_strings iniciou no 0 e na linha 41 | |
# é feito a incrementação. Portanto o while irá ser executado até iterar por todos os elementos/strings da lista_entrada | |
while contador_strings < len(lista_entrada): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Word(object): | |
def __init__(self): | |
self.vowels = ["A", "a", "á", "ã", "â", "à", "E", "e", "é", "ê", "I", "i", "í", "O", "o", "ó", "õ", "ô", "U", "u", "ú", "Y", "y"] | |
self.others_char = [" ", ",", ".", ";", "!", "?", "-", "_", "'", '"', "*", "+", "/"] | |
def vowels_count(self, phrase): | |
''' Percorre a frase e conta somente as vogais. ''' | |
count_vowels = 0 | |
for char in phrase: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# V 0.0.1 | |
# 2021-02-28 | |
# Inspired by Regis do Python - https://github.com/rg3915 | |
# Shell script to create a very simple Django project. | |
# This script require Python 3.x and pyenv | |
# Settings.py is config to Django 2.2.19 | |
# The project contains: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
$('select').on('change', inicio); | |
function inicio(){ | |
var id = $(this).val(); | |
var cat = {{pk}}; | |
dados = {'id':id, 'cat':cat}; | |
$.ajax({ | |
data : dados, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Django settings for eventex project. | |
For more information on this file, see | |
https://docs.djangoproject.com/en/1.6/topics/settings/ | |
--- a/eventex/settings.py | |
+++ b/eventex/settings.py | |
@@ -8,9 +8,8 @@ For the full list of settings and their values, see | |
https://docs.djangoproject.com/en/1.6/ref/settings/ | |
""" |