Skip to content

Instantly share code, notes, and snippets.

View carturoch's full-sized avatar
🏠
Working from home

Carlos Cuellar carturoch

🏠
Working from home
  • Miami, FL
View GitHub Profile
require 'open-uri'
1.upto(12) do |i|
remote_path = "https://via.placeholder.com/650x300/069/AAA?text=#{i}"
open("check_front_#{i}.png", 'wb') do |f|
f << open(remote_path).read
puts "downloaded #{i}"
end
end
@carturoch
carturoch / sums.rb
Created March 5, 2018 22:34
Nicer solution
def sums(list, interval)
list
.each_slice(interval)
.to_a
.map { |sublist| sublist.reduce :+ }
end

Keybase proof

I hereby claim:

  • I am carturoch on github.
  • I am carturoch (https://keybase.io/carturoch) on keybase.
  • I have a public key ASBKXonp2elr53zY3cxtKedLzGSVfYGAuGqMTBZ6fhA2iAo

To claim this, I am signing this object: