active_recall 1.6.2 → 1.6.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +9 -9
- data/lib/active_recall/algorithms/fibonacci_sequence.rb +4 -2
- data/lib/active_recall/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2e993b98e9627ec06e8eae73c3fba15a6ed761b66dbb1092b1355140cb2bd366
|
4
|
+
data.tar.gz: 5402a3ae205e52b20587ab73a5d819eaf7102dea5d52cf983e4be5beddf5279d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: aba48fb3870fd48fba35a371b48ceeaad4fb306acef718175f67451ee25111ec6389faaf0c52d9424ad1b87da94faf1c24b66f32f920392fa4b7e68ebbb27699
|
7
|
+
data.tar.gz: 2c9c4651bd1e4ac541ffb4c258e899bf311cd84ec6cc4490b643ef1a27bc236c9820e5e30b5af22ee4673413dfad5e0bacbdbcd7344494c9df2059e3472fee17
|
data/Gemfile.lock
CHANGED
@@ -1,27 +1,27 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
active_recall (1.6.
|
4
|
+
active_recall (1.6.3)
|
5
5
|
activerecord (>= 5.2.3, <= 6.2)
|
6
6
|
activesupport (>= 5.2.3, <= 6.2)
|
7
7
|
|
8
8
|
GEM
|
9
9
|
remote: https://rubygems.org/
|
10
10
|
specs:
|
11
|
-
activemodel (6.1.
|
12
|
-
activesupport (= 6.1.
|
13
|
-
activerecord (6.1.
|
14
|
-
activemodel (= 6.1.
|
15
|
-
activesupport (= 6.1.
|
16
|
-
activesupport (6.1.
|
11
|
+
activemodel (6.1.4)
|
12
|
+
activesupport (= 6.1.4)
|
13
|
+
activerecord (6.1.4)
|
14
|
+
activemodel (= 6.1.4)
|
15
|
+
activesupport (= 6.1.4)
|
16
|
+
activesupport (6.1.4)
|
17
17
|
concurrent-ruby (~> 1.0, >= 1.0.2)
|
18
18
|
i18n (>= 1.6, < 2)
|
19
19
|
minitest (>= 5.1)
|
20
20
|
tzinfo (~> 2.0)
|
21
21
|
zeitwerk (~> 2.3)
|
22
|
-
concurrent-ruby (1.1.
|
22
|
+
concurrent-ruby (1.1.9)
|
23
23
|
diff-lcs (1.3)
|
24
|
-
i18n (1.8.
|
24
|
+
i18n (1.8.10)
|
25
25
|
concurrent-ruby (~> 1.0)
|
26
26
|
minitest (5.14.4)
|
27
27
|
rake (12.3.3)
|
@@ -51,9 +51,11 @@ module ActiveRecall
|
|
51
51
|
|
52
52
|
attr_reader :box, :current_time, :times_right, :times_wrong
|
53
53
|
|
54
|
+
SEQUENCE = [0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, 233, 377, 610, 987, 1597, 2584, 4181, 6765].freeze
|
55
|
+
|
54
56
|
def fibonacci_number_at(index)
|
55
|
-
if (0
|
56
|
-
index
|
57
|
+
if (0...SEQUENCE.length).cover?(index)
|
58
|
+
SEQUENCE[index]
|
57
59
|
else
|
58
60
|
fibonacci_number_at(index - 1) + fibonacci_number_at(index - 2)
|
59
61
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: active_recall
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.6.
|
4
|
+
version: 1.6.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Robert Gravina
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date: 2021-
|
12
|
+
date: 2021-08-12 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rake
|