Skip to content

Instantly share code, notes, and snippets.

Davide D'Agostino DAddYE

Block or report user

Report or block DAddYE

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View keybase.md

Keybase proof

I hereby claim:

  • I am daddye on github.
  • I am daddye (https://keybase.io/daddye) on keybase.
  • I have a public key whose fingerprint is 8F39 912A 097E 377E 1E00 32CD AF60 5C47 8698 A064

To claim this, I am signing this object:

View fix permissions brew.sh
cd /usr/local
sudo chown -R daddye:admin .
git init
git remote | while read i; do git remote remove $i; done
git reset --hard
git remote add -m master -t master -f --tags origin git://github.com/mxcl/homebrew.git
@DAddYE
DAddYE / The Technical Interview Cheat Sheet.md
Last active Aug 25, 2015 — forked from TSiege/The Technical Interview Cheat Sheet.md
This is my technical interview cheat sheet. Feel free to fork it or do whatever you want with it. PLEASE let me know if there are any errors or if anything crucial is missing. I will add more links soon.
View The Technical Interview Cheat Sheet.md

Studying for a Tech Interview Sucks, so Here's a Cheat Sheet to Help

This list is meant to be a both a quick guide and reference for further research into these topics. It's basically a summary of that comp sci course you never took or forgot about, so there's no way it can cover everything in depth. It also will be available as a gist on Github for everyone to edit and add to.

Data Structure Basics

###Array ####Definition:

  • Stores data elements based on an sequential, most commonly 0 based, index.
  • Based on tuples from set theory.
@DAddYE
DAddYE / example.rb
Last active Aug 29, 2015 — forked from hamin/example.rb
An updated Rust 1.x version of Yehuda's Native Rust Extension post here http://blog.skylight.io/bending-the-curve-writing-safe-fast-native-gems-with-rust/
View example.rb
require "./points"
p1 = RustPoint::make_point(10, 10) # => #<Fiddle::Pointer:0x007f8231e56510 ptr=0x0000010b824000 size=0 free=0x00000000000000>
p2 = RustPoint::make_point(20, 20) # => #<Fiddle::Pointer:0x007f8231f20970 ptr=0x0000010b824010 size=0 free=0x00000000000000>
RustPoint::get_distance(p1, p2) # => 14.142135623730951
@DAddYE
DAddYE / randomID.go
Created Jul 30, 2015
Generate pseudo random numbers
View randomID.go
package main
import (
"crypto/rand"
"math/big"
)
var maxID = new(big.Int).SetUint64(^uint64(0))
func genRandomID() uint64 {
@DAddYE
DAddYE / vim.md
Last active Aug 29, 2015
Shortcuts that I tend to forget.
View vim.md

CtrlP

<F5>  " to purge the cache for the current directory to get new files, remove deleted files and apply new ignore options.
<c-f> " and `<c-b>` to cycle between modes.
<c-d> " to switch to filename only search instead of full path.
<c-r> " to switch to regexp mode.
<c-t> " or `<c-v>`, `<c-x>` to open the selected entry in a new tab or in a new split.
<c-z> " to mark/unmark multiple files and `<c-o>` to open them.
View opencv.rb
require 'formula'
class Opencv < Formula
homepage 'http://opencv.org/'
url 'https://github.com/Itseez/opencv/archive/2.4.9.tar.gz'
sha1 'd16ced627db17f9864c681545f18f030c7a4cc0b'
# CUDA needs 2.4.10 (see #1228)
# url 'https://github.com/Itseez/opencv/archive/2.4.10.tar.gz'
# sha1 'a0c2d5944364fc4f26b6160b33c03082b1fa08c1'
head 'https://github.com/Itseez/opencv.git'
@DAddYE
DAddYE / chan.go
Created Sep 13, 2014
Infinitely Buffered Channel
View chan.go
/*
This is an infinitely buffered channel.
*/
package main
import (
"fmt"
"sync"
"time"
)
View designer.html
<link rel="import" href="../core-scaffold/core-scaffold.html">
<link rel="import" href="../core-header-panel/core-header-panel.html">
<link rel="import" href="../core-menu/core-menu.html">
<link rel="import" href="../core-item/core-item.html">
<link rel="import" href="../core-icon-button/core-icon-button.html">
<link rel="import" href="../core-toolbar/core-toolbar.html">
<link rel="import" href="../core-menu/core-submenu.html">
<link rel="import" href="../chart-js/chart-js.html">
<polymer-element name="my-element">
View designer.html
<link rel="import" href="../core-scaffold/core-scaffold.html">
<link rel="import" href="../core-header-panel/core-header-panel.html">
<link rel="import" href="../core-menu/core-menu.html">
<link rel="import" href="../core-item/core-item.html">
<link rel="import" href="../core-icon-button/core-icon-button.html">
<link rel="import" href="../core-toolbar/core-toolbar.html">
<link rel="import" href="../core-menu/core-submenu.html">
<link rel="import" href="../chart-js/chart-js.html">
<polymer-element name="my-element">
You can’t perform that action at this time.