essas batalhas sobre linguagens de programação sao frequententes, mas muitos ignoram que tudo vira instruções que a máquina é capaz de executar então, no inicio, a programação era complicada, com fios (isso falando de computadores modernos, da época da segunda guerra depois, com o desenvolvimento das memórias, viu-se a vantagem de tornar a programação flexivel e armazena-la na memoria (agora abundante) os computadores e os programas começaram a crescer entao eles programavam apenas em código de máquina, instruções que eram codificadas para cada processador depois veio a ideia de agrupar instrucoes semelhantes em menemonicos aparece o assembly uma instrucao em assembly pode gerar varias instrucoes de maquina diferente mov Registrador, memoria mov memoria, Registrador
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
estado | pib | codigo | area | população | idh | receita | despesa | |
---|---|---|---|---|---|---|---|---|
Rondônia | 39450587 | 11 | 237765233 | 1757589 | 690 | 9122310.72305 | 7085530.0168 | |
Acre | 13751126 | 12 | 164123738 | 869265 | 663 | 6632883.10836 | 6084416.8063 | |
Amazonas | 89017165 | 13 | 1559168117 | 4080611 | 674 | 17328459.43402 | 15324896.55705 | |
Roraima | 11011454 | 14 | 224273831 | 576568 | 707 | 4419450.41557 | 3384683.73914 | |
Pará | 138068008 | 15 | 1245759305 | 8513497 | 646 | 25849446.10454 | 22533470.04547 | |
Amapá | 14338838 | 16 | 142470762 | 829494 | 708 | 5396417.14471 | 4224464.08829 | |
Tocantins | 31575831 | 17 | 277720404 | 1555229 | 699 | 10305099.01288 | 8929456.43836 | |
Maranhão | 85286226 | 21 | 329642170 | 7035055 | 639 | 18503261.35491 | 17627170.75574 | |
Piauí | 41405815 | 22 | 251616823 | 3264531 | 646 | 12124215.61511 | 9676736.31835 |
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
import re | |
titles = ['Deputado Federal ', 'General ', 'Ex-presidente ', 'Senadora ', 'Senador ', 'do Exército', 'Tenente-Brigadeiro'] | |
novas_linhas = [] | |
for _, row in agenda2016_limpa_final.iterrows(): | |
nova_linha = [row["oque"], row["onde"], row["ano"], row["mes"], row["dia"], row["hora"]] | |
pessoas = [re.sub('|'.join(titles),'',i.split(', ')[0]) for i in row["oque"].split('; ')] | |
for pessoa in pessoas: | |
linha_com_pessoa = nova_linha[:] # o lista[:] eh para copiar a lista | |
linha_com_pessoa.append(pessoa) | |
novas_linhas.append(linha_com_pessoa) |
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
" general tab as space conf | |
set tabstop=4 " The width of a TAB is set to 4. | |
" Still it is a \t. It is just that | |
" Vim will interpret it to be having | |
" a width of 4. | |
set shiftwidth=4 " Indents will have a width of 4 | |
set softtabstop=4 " Sets the number of columns for a TAB |
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
from datetime import datetime, timedelta | |
from airflow import DAG | |
from airflow.operators import PythonOperator | |
start_date = datetime.now() | |
default_args = { | |
'owner': 'ab-analytics', | |
'depends_on_past': False, |
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
package main | |
import ( | |
"fmt" | |
"os" | |
"github.com/tsuru/config" | |
"github.com/tsuru/tsuru/auth" | |
"github.com/tsuru/tsuru/db" | |
"github.com/tsuru/tsuru/permission" |
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
# using redis library: https://pypi.python.org/pypi/redis | |
import redis, os | |
HOST = os.getenv("HOST", "localhost") | |
PORT = os.getenv("PORT", 6379) | |
r = redis.StrictRedis(host=HOST, port=PORT) | |
cnames_app = r.keys("cname:*") | |
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
from ubuntu | |
run ls |
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
import os | |
import redis | |
from pymongo import MongoClient | |
mongo_host = os.getenv("MONGO_HOST", "localhost") | |
mongo_port = os.getenv("MONGO_PORT", "27017") | |
mongo_client = MongoClient(mongo_host, int(mongo_port)) | |
redis_host = os.getenv("REDIS_HOST", "localhost") |
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
package main | |
import ( | |
"io" | |
"os" | |
"strings" | |
) | |
type rot13Reader struct { | |
r io.Reader |
NewerOlder