Sha256: 0743e5ea5eb8a2770c54f2c9cd8a441474ed1cceaf43eaff4a48ca90f432d9a4
Contents?: true
Size: 373 Bytes
Versions: 1
Compression:
Stored size: 373 Bytes
Contents
module GridGenerator class Line def initialize(a:, b:) @a, @b = a, b end attr_reader :a, :b def ==(other) self.class == other.class && self.a == other.a && self.b == other.b end def x1 a[0,0] end def y1 a[1,0] end def x2 b[0,0] end def y2 b[1,0] end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
grid_generator-0.2.10 | lib/grid_generator/line.rb |