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
| <? | |
| # MIT license, do whatever you want with it | |
| # | |
| # This is my invoice.php page which I use to make invoices that customers want, | |
| # with their address on it and which are easily printable. I love Stripe but | |
| # their invoices and receipts were too wild for my customers on Remote OK | |
| # | |
| require_once(__DIR__.'/../vendor/autoload.php'); |
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
| print('===CALCULADORA LATAS DE CERVEJA PARA KM===\n\n') | |
| # Pergunta quantos kg de latas ele quer verificar | |
| pesoLatas = input('Quantos KG de latas você tem?\n') | |
| # Lista com quantidade (em ML) que as latas são comercializadas | |
| latasML = [ | |
| 269, | |
| 350, | |
| 473 |
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
| print('===CALCULADOR DE CONSUMO MENSAL DE ENERGIA===\n\n') | |
| aparelho = input('Qual aparelho você quer saber o consumo mensal? \n') | |
| watt = input('Quantos Watts esse aparelho consome? \n') | |
| hrs = input('Quantas horas esse aparelho fica ligado por dia? \n') | |
| custo = input('Quanto custa o kW/h na sua região? (em reais) \n') | |
| #Quantos Quilo Watt/Hora o aparelho consome | |
| kWh = (float(watt) / 1000) * float(hrs) |