This file contains hidden or 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
version: '3' | |
services: | |
bd: | |
image: postgres | |
restart: always | |
environment: | |
- POSTGRES_USER=postgres | |
- POSTGRES_PASSWORD=postgres | |
- POSTGRES_DB=postgres |
This file contains hidden or 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 pandas | |
doi_ids = [] | |
for i in range(1,10): | |
nome_arquivo = f'PsycNET_Export({i}).csv' | |
print("File readed: %s" % nome_arquivo) | |
df = pandas.read_csv(nome_arquivo) | |
for index,row in df.iterrows(): | |
doi_ids.append(row['DOI']) |
This file contains hidden or 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
#user nobody; | |
worker_processes 1; | |
#error_log logs/error.log; | |
#error_log logs/error.log notice; | |
#error_log logs/error.log info; | |
#pid logs/nginx.pid; |
This file contains hidden or 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
#include <stdio.h> | |
#include <stdlib.h> | |
/* | |
Descrição: Verifica se as dimensões do triângulo são positivas ou negativas | |
Parâmetros: | |
- a,b,c: lados do triângulo | |
Retorno: 0 -> Lados inválidos, 1 -> Lados válidos | |
*/ | |
int verifica_lados(int a,int b,int c){ | |
return (a <= 0 || b <= 0 || c <= 0)? 0 : 1; |
This file contains hidden or 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
select bubu.departamento as departamento, toucinho.div as divisao,bubu.maximo as media from | |
--Seleciona o nome e o valor da maior média salarial de uma divisão do departamento | |
(select div_dep.depar as departamento,max(div_dep.media) as maximo from ( | |
select dep.nome as depar,div.nome,round(avg(vencimentos.salario_bruto-descontos.desconto),2) as media | |
from | |
(( select e.matr as mat, coalesce(sum(v.valor),0) as salario_bruto from empregado as e | |
left join emp_venc as ev on (ev.matr = e.matr) | |
left join vencimento as v on (v.cod_venc = ev.cod_venc) | |
group by e.matr) as vencimentos | |
inner join |