co2_travel_calc 0.0.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/co2_travel_calc.rb +18 -0
  3. metadata +42 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 537f5092222225da141ef4a186ec7ae5f50b686f5821a96dfdfc53cee02f4b08
4
+ data.tar.gz: 9ba67cef9becee9861e17d1dad845af3d473218bc5d0820696836035afa582bd
5
+ SHA512:
6
+ metadata.gz: d83f1426e99faaf10c9293414c6b9b18827998dc1489522fb55b5955bc5abc17cdd17e8da4084483ab4fb81d5d552aa4b66835c0966c49dbe9cea132e71d5585
7
+ data.tar.gz: fdfef1587614cd84c950cdf593a3901882b4fabecd4fade013c6182fc2ac9b53e8e90ba6d99c796aabc88d382920a761e70b0e14e40ad1f83f2bee2e2384c668
@@ -0,0 +1,18 @@
1
+ module CarbonCalcCar
2
+
3
+ def self.checkCar(totalKm)
4
+
5
+ @totalKm = totalKm
6
+ @totalEmmissionCar = @totalKm * 0.112
7
+
8
+
9
+ end
10
+
11
+
12
+ def self.checkPlane(totalKm)
13
+
14
+ @totalEmissionPlane = @totalKm * 0.285
15
+
16
+ end
17
+
18
+ end
metadata ADDED
@@ -0,0 +1,42 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: co2_travel_calc
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.0
5
+ platform: ruby
6
+ authors:
7
+ - Dao Odris
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2022-05-12 00:00:00.000000000 Z
12
+ dependencies: []
13
+ description: Simple estimate for CO2 emissions from cars and plane
14
+ email: x19219318@student.ncirl.ie
15
+ executables: []
16
+ extensions: []
17
+ extra_rdoc_files: []
18
+ files:
19
+ - lib/co2_travel_calc.rb
20
+ homepage: http://rubygems.org/gems/co2_travel_calc
21
+ licenses: []
22
+ metadata: {}
23
+ post_install_message:
24
+ rdoc_options: []
25
+ require_paths:
26
+ - lib
27
+ required_ruby_version: !ruby/object:Gem::Requirement
28
+ requirements:
29
+ - - ">="
30
+ - !ruby/object:Gem::Version
31
+ version: '0'
32
+ required_rubygems_version: !ruby/object:Gem::Requirement
33
+ requirements:
34
+ - - ">="
35
+ - !ruby/object:Gem::Version
36
+ version: '0'
37
+ requirements: []
38
+ rubygems_version: 3.3.8
39
+ signing_key:
40
+ specification_version: 4
41
+ summary: Calculate Emissions
42
+ test_files: []