bmi-antonio 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +7 -0
  2. data/lib/body_mass_index.rb +11 -0
  3. metadata +44 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: fe1805cc195be6055e738b3574a6ee9cfeaf2667
4
+ data.tar.gz: bb532b3a8b25856c388130bf9203028abe4ce76e
5
+ SHA512:
6
+ metadata.gz: 641e806d614b105898401ae56f8612cd5a92a89fde7ddcf408c0611e7ce9542cb144f73c13973ecf8e2ec726d2c859a88f5ddc78209bf11fd1bb811df58ce661
7
+ data.tar.gz: 65e8c638af935785145716b228eb4dff8fa5f578aa214dc9c422e8d9416c0e96d830ecdb36bc2be7ed7d80c2fd8a2f47d53fc2128c7cf0be4a7a506801d13429
@@ -0,0 +1,11 @@
1
+ class BodyMassIndex
2
+ attr_reader :height, :mass
3
+
4
+ def initialize(height, mass)
5
+ @height, @mass = height, mass
6
+ end
7
+
8
+ def calculate_index
9
+ (mass / (height ** 2)).round(2)
10
+ end
11
+ end
metadata ADDED
@@ -0,0 +1,44 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: bmi-antonio
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Antonio Chavez
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2015-11-18 00:00:00.000000000 Z
12
+ dependencies: []
13
+ description: "...."
14
+ email: antonio.chavez@itcolima.edu.mx
15
+ executables: []
16
+ extensions: []
17
+ extra_rdoc_files: []
18
+ files:
19
+ - lib/body_mass_index.rb
20
+ homepage: https://rubygems.org/TheNaoX/bmi-antonio
21
+ licenses:
22
+ - MIT
23
+ metadata: {}
24
+ post_install_message:
25
+ rdoc_options: []
26
+ require_paths:
27
+ - lib
28
+ required_ruby_version: !ruby/object:Gem::Requirement
29
+ requirements:
30
+ - - ">="
31
+ - !ruby/object:Gem::Version
32
+ version: '0'
33
+ required_rubygems_version: !ruby/object:Gem::Requirement
34
+ requirements:
35
+ - - ">="
36
+ - !ruby/object:Gem::Version
37
+ version: '0'
38
+ requirements: []
39
+ rubyforge_project:
40
+ rubygems_version: 2.4.8
41
+ signing_key:
42
+ specification_version: 4
43
+ summary: "..."
44
+ test_files: []