twisty_puzzles 0.0.29 → 0.0.30
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/twisty_puzzles/cube.rb +1 -1
- data/lib/twisty_puzzles/part_cycle.rb +1 -1
- data/lib/twisty_puzzles/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e0921468026dd18bfa906d172939b0856c6d98081eff7fe2013e168daa66f090
|
4
|
+
data.tar.gz: 91ef593d14bc93213d6703d508c392ba0ca24d05cd20bfc6936391f0afb7a2ad
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5be09b84d72b7c36723fa4003fdb3ec7a8f068ae5c95e6e10956468f74c3730acb22de0e06b388a42b34c2b2af04bf62bf3cdedd5cf5d472fca70750f7735dd6
|
7
|
+
data.tar.gz: a842caaa9cebd5cdadc38cbf60c22439b49b1d923682fbfdd06a69ea92ccf3916c45bbe4c6c317f9fcc6b37d8d41fe81e9443717cf45c009548f474ad2c00142
|
data/lib/twisty_puzzles/cube.rb
CHANGED
@@ -74,7 +74,7 @@ module TwistyPuzzles
|
|
74
74
|
|
75
75
|
def self.exists_on_cube_size?(cube_size)
|
76
76
|
cube_size >= min_cube_size && cube_size <= max_cube_size &&
|
77
|
-
(cube_size
|
77
|
+
(cube_size.even? ? exists_on_even_cube_sizes? : exists_on_odd_cube_sizes?)
|
78
78
|
end
|
79
79
|
|
80
80
|
def num_incarnations(_cube_size)
|
@@ -17,7 +17,7 @@ module TwistyPuzzles
|
|
17
17
|
|
18
18
|
RAW_DATA_RESERVED = [' ', '(', ')'].freeze
|
19
19
|
|
20
|
-
def initialize(parts, twist=0)
|
20
|
+
def initialize(parts, twist = 0)
|
21
21
|
raise ArgumentError if parts.empty?
|
22
22
|
raise TypeError unless twist.is_a?(Integer)
|
23
23
|
raise ArgumentError if twist.negative?
|