hiking_calories_calculator 0.1.2 copy "hiking_calories_calculator: ^0.1.2" to clipboard
hiking_calories_calculator: ^0.1.2 copied to clipboard

A calculator for calculating burned calories during hiking using Pandolf Equation.

example/main.dart

// Author: Birju Vachhani (https://github.com/birjuvachhani)
// Created Date: January 06, 2020

import 'package:hiking_calories_calculator/calculator/calculation.dart';
import 'package:hiking_calories_calculator/calculator/calories_calculator.dart';
import 'package:hiking_calories_calculator/calculator/speed.dart';
import 'package:hiking_calories_calculator/calculator/terrain_factors.dart';
import 'package:hiking_calories_calculator/calculator/weight.dart';

void main() {
  Calculation calculation = CaloriesCalculator.calculateCalories(
      weight: Weight(lbs: 120),
      bagWeight: Weight(lbs: 20),
      speed: Speed(mph: 4),
      terrain: Terrains.WET_CLAY_OR_ICE,
      inclination: 0);
  print("\nCalories per Hour:");
  print(calculation.kcalPerHour.ceil().toString());
  print("\nCalories per Mile:");
  print(calculation.kcalPerMile.ceil().toString());
}
6
likes
40
pub points
0%
popularity

Publisher

verified publishersimform.com

A calculator for calculating burned calories during hiking using Pandolf Equation.

Homepage

License

Apache-2.0 (license)

Dependencies

meta

More

Packages that depend on hiking_calories_calculator