Sha256: 8f2a650dfa1f495a422ef2ee9ef00edcde66a9b85c471594fc9601debff24e0a
Contents?: true
Size: 279 Bytes
Versions: 1
Compression:
Stored size: 279 Bytes
Contents
#!/usr/bin/env ruby # frozen_string_literal: true require_relative "setup" require "ryo" point_x = Ryo(x: 2) point_y = Ryo({y: 4}, point_x) point = Ryo({}, point_y) Ryo.map!(point) { |key, value| value * 2 } p [point.x, point.y] p [point_x.x, point_y.y] ## # [4, 8] # [4, 8]
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
ryo.rb-0.5.6 | share/ryo.rb/examples/2.1_iteration_map.rb |