Sha256: baa85f722a81d7b79d4c940bab40675572db03373f79b8ee4979078cf4c1e14f
Contents?: true
Size: 291 Bytes
Versions: 2
Compression:
Stored size: 291 Bytes
Contents
module Straightedge module Figures class Line < Figure def alpha @marks[0] end def beta @marks[1] end def dx alpha.x - beta.x end def dy alpha.y - beta.y end def length Math.sqrt(dx*dx + dy*dy) end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
straightedge-0.1.2 | lib/straightedge/figures/line.rb |
straightedge-0.1.1 | lib/straightedge/figures/line.rb |