compilar projecto

This commit is contained in:
2025-10-05 22:16:20 +01:00
parent 41a3dd4da6
commit cb4a51a52a
11 changed files with 233 additions and 9 deletions

View File

@ -45,7 +45,8 @@ portfolio_headers = ["data", "moeda", "quantidade", "movimento"]
# introduzir quantidade de criptomoeda detida
qtd_criptomoeda = float(
input(f"Introduza valor de {criptomoeda} detida: ").replace(",", "."))
input(f"Introduza valor de {criptomoeda} detida: ").replace(",", ".")
)
# se não houver ficheiro 'dados/{criptomoeda}.csv' criar ficheiro
caminho_ficheiro_historico_csv = f"./dados/{criptomoeda}.csv"
@ -131,9 +132,8 @@ for item in dados:
cripto_vs_euro = float(dados[len(dados) - 1][cabecalho[6]])
# valor em eur da quantidade de criptomoeda detida
print(
f"Valor de {qtd_criptomoeda} {criptomoeda} em EUR: {
(qtd_criptomoeda * cripto_vs_euro):.2f
}"
f"Valor de {qtd_criptomoeda} {criptomoeda} em EUR: \
{(qtd_criptomoeda * cripto_vs_euro):.2f}"
)