I have a problem that pretty much boils down to this:
a = [1, 2, 3]
b = [1.1, 2.2, 3.3]
# BEGIN GROSS SOLUTION: avert your eyes!
results = [ ]
a.each do |i|
b.each do |j|
#!/usr/bin/python3 | |
import sys | |
if len(sys.argv) != 3: | |
print("Usage: %s <input> <distro>" % (sys.argv[0])) | |
sys.exit(1) | |
infile = sys.argv[1] | |
distro = sys.argv[2] |
I have a problem that pretty much boils down to this:
a = [1, 2, 3]
b = [1.1, 2.2, 3.3]
# BEGIN GROSS SOLUTION: avert your eyes!
results = [ ]
a.each do |i|
b.each do |j|
[16:56:05] <k1t___> youre making a mistake | |
[16:56:18] <k1t___> i promise you motherfucker | |
[16:56:28] <k1t___> adrian lamo | |
[16:56:31] <k1t___> kevin mitnick | |
[16:56:38] <k1t___> these dont ring bells? | |
[16:56:50] <k1t___> my friends you fucking faggot stupid motherfucker | |
[16:56:56] <k1t___> ill own your soul you faggot | |
[16:57:19] <k1t___> and your moms | |
[16:57:25] <k1t___> and your pathetic fathers |
class Wat | |
attr_accessor :collaborator, :credentials | |
def foo(arg) | |
@collaborator.foo(arg) | |
rescue | |
@collaborator.set_auth_credentials(credentials) | |
@collaborator.foo(arg) | |
end |
L1 cache reference 0.5 ns | |
Branch mispredict 5 ns | |
L2 cache reference 7 ns 14x L1 cache | |
Mutex lock/unlock 25 ns | |
Main memory reference 100 ns 20x L2 cache, 200x L1 cache | |
Compress 1K bytes with Zippy 3,000 ns | |
Send 1K bytes over 1 Gbps network 10,000 ns 0.01 ms | |
Read 1 MB sequentially from memory 250,000 ns 0.25 ms | |
Round trip within same datacenter 500,000 ns 0.5 ms | |
Read 1 MB sequentially from SSD 1,000,000 ns 1 ms 4X memory |
# MOTIVATION: As rails apps are growing, people are noticing the drawbacks | |
# of the ActiveRecord pattern. Several apps I have seen, and several | |
# developers I have spoken to are looking towards other patterns for object | |
# persistence. The major drawback with ActiveRecord is that the notion | |
# of the domain object is conflated with what it means to store/retrieve | |
# it in any given format (like sql, json, key/value, etc). | |
# | |
# This is an attempt to codify the Repository pattern in a way that would | |
# feel comfortable to beginner and seasoned Ruby developers alike. | |
# |
#!/usr/bin/env ruby | |
# giftube – Generates an animated gif from a YouTube url. | |
# | |
# Usage: | |
# | |
# giftube [youtube url] [minute:second] [duration] | |
# | |
# ex. | |
# |
# stream video from your desktop & audio from another device into an h264/mp3 avi video with VLC | |
vlc screen:// --screen-fps=12 \ | |
--input-slave=alsa://hw:1,0 \ | |
--qt-start-minimized \ | |
--sout "#transcode{venc=x264,vcodec=h264,fps=12,vb=640,acodec=mp3,channels=1,ab=64}\ | |
:std{access=file,mux=mp4,dst=screencam-$(date -u +%Y-%m-%d-%s).avi}" |
From: Matthew Greenburg <[email protected]> | |
CC: Carl Narcisse <[email protected]> | |
Blake, | |
My name is Matt Greenburg with Astreya Partners, an IT staffing company in Santa Clara. We bring on full time employees of Astreya to work on-site at our clients' locations. I came across your resume and was wondering if you were entertaining new career opportunities at this time. I think you would be a great fit for a position we have open as a Web Application Developer, Ruby on Rails.This position is located in Cupertino, CA at a large very well known company. Think big! | |
Web Application Developer, Ruby on Rails | |
Successful team members must be able to document, design, develop, validate and maintain complete solutions to specific business needs with minimal supervisory input in a dynamic, result driven environment. These contributors need a wide variety and depth of web-related (including associated back end) technical skills and are well organized, self-motivated people with excellent communication skills |
def maybe_a_sandwich | |
nil | |
end | |
# Methods that might return nil are annoying. We want to write a nice | |
# confident chain: | |
result = nil | |
result = maybe_a_sandwich.add_horseradish.get_into_my_belly! rescue $! | |
result # => #<NoMethodError: undefined method `add_horseradish' for nil:NilClass> |