Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Bibliotecas
- import 'dart:io';
- // Funcao principal
- main() {
- // Funcao
- print(entDados());
- }
- // Funcao: Entrada de dados
- int entDados() {
- // Variaveis
- int d, h, m;
- stdout.write("# Dias: ");
- d = int.parse(stdin.readLineSync()!);
- stdout.write("# Horas: ");
- h = int.parse(stdin.readLineSync()!);
- stdout.write("# Minutos: ");
- m = int.parse(stdin.readLineSync()!);
- return calculoSeg(d, h, m);
- }
- // Calculo
- int calculoSeg(int d, int h, int m) {
- return 60 * (d * 24 * 60 + h * 60 + m);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement