Skip to content

Instantly share code, notes, and snippets.


Emanuele DelBono emadb

Block or report user

Report or block emadb

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
emadb / app.js
Last active Aug 29, 2015
Angular directive rendering.
View app.js = angular.module('myApp', []);'mainController', function($scope){
$scope.title = "Demo";
console.log('Controller: click');
View gist:906a5fee800480e079f2
/*jslint node: true */
"use strict";
module.exports = function (grunt) {
View gist:924b2a9f28e8fb3c6c2d
var obj1 = {
foo: function(){;
obj1Callback: function(){
// do something
var obj2 = {
emadb / index.html
Last active Sep 15, 2016
JS Bin - Reactjs bootstrap modal example // source,js,output
View index.html
<!DOCTYPE html>
<meta name="description" content="Reactjs bootstrap modal example">
<script src=""></script>
<script src=""></script>
<link href="" rel="stylesheet" type="text/css" />
<script src=""></script>
<script src=""></script>
<meta charset="utf-8">
View Seti_modified.sublime-theme
// Tab set
"class": "tabset_control",
"layer0.texture": "Seti_UI/Main/tabset-background.png",
"layer0.inner_margin": [1, 7],
"layer0.opacity": 1,
emadb / Comp.ex
Last active Aug 29, 2015
View Comp.ex
defmodule Comp do
def check([h|t], b) do
check(t, List.delete(b, h*h))
def check(_,[]), do: true
def check([], b), do: false
emadb / async kata
Last active Aug 29, 2015
Kata - synchronize asyncrounous results
View async kata
Consider to have a series of calculators functions that need to run in series.
These calculators are asynchronous and any of those can return a value (a number >=0) or an error (-1).
Calculators must be evaluated in order and you have to write a function that returns the value of the first calculator
that doesn't fail. For first I mean the first in the chain of calculators.
Test case
function calculator1(resultCallback){
setTimeout(function(){ resultCallback(-1) }, 1000);
emadb / Sample.cs
Last active Aug 29, 2015
Run a set of tasks and wait for the first (in run order) that succeed
View Sample.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
namespace ConsoleApplication1
class Program
View gist:8ef2832f83e6bd62cfa1
Verifying that +emanueledelbono is my blockchain ID.
You can’t perform that action at this time.