This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void setup() { | |
circle(50, 50, 10); | |
} | |
void draw() { | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void setup() { | |
circle(50, 50, 10); | |
} | |
void draw() { | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// A basic everyday NeoPixel strip test program. | |
// NEOPIXEL BEST PRACTICES for most reliable operation: | |
// - Add 1000 uF CAPACITOR between NeoPixel strip's + and - connections. | |
// - MINIMIZE WIRING LENGTH between microcontroller board and first pixel. | |
// - NeoPixel strip's DATA-IN should pass through a 300-500 OHM RESISTOR. | |
// - AVOID connecting NeoPixels on a LIVE CIRCUIT. If you must, ALWAYS | |
// connect GROUND (-) first, then +, then data. | |
// - When using a 3.3V microcontroller with a 5V-powered NeoPixel strip, | |
// a LOGIC-LEVEL CONVERTER on the data line is STRONGLY RECOMMENDED. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<base href="https://docraptor.com/"> | |
<title>Five Things You Should Know About HTML5 - Dive Into HTML5</title> | |
<link rel="stylesheet" href="/samples/diveintohtml5.screen.css"> | |
<style> | |
h1:before { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Text; | |
namespace AzureMediaServicesEncoderNetCore.Services | |
{ | |
class MediaServices | |
{ | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
namespace AzureMediaServicesEncoderNetCore | |
{ | |
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
// this is a big no-no in practice! never hard-code sensitive data or commit it to a repository | |
// a better approach would be to use a ConfigurationBuilder instance: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Azure.MediaServices.Core; | |
using System; | |
namespace AzureMediaTool | |
{ | |
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
string tenantDomain = "--"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Patch the a `track` method on the mixpanel library | |
// This method is identical to `mixpanel.track`, but it executes the callback if mixpanel has not returned within 350ms | |
// Addresses an issue in the mixpanel library where the library has not been loaded (becuase of a timeout or blocked by ad blocker), | |
// and the initialized version is used instead. Due to a bug in the mixpanel loader, callbacks are never triggered when this occurs | |
var unpatchedMixpanelTrack = mixpanel.track; | |
mixpanel.track = function(event_name, properties, callback) { | |
if(!callback) { | |
return unpatchedMixpanelTrack(event_name, properties); | |
} else { | |
// make it 50ms over mixpanel's default 300ms callback timeout |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
syntax on | |
filetype plugin indent on | |
" Set a backup directory | |
" silent !mkdir ~/.vim/tmp > /dev/null 2>&1 set backupdir=~/.vim/tmp | |
set noswapfile | |
" Source the vimrc file after saving it | |
" via: http://vimcasts.org/episodes/updating-your-vimrc-file-on-the-fly/ | |
if has("autocmd") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class BinaryTreeNode(object): | |
value = None | |
left = None | |
right = None | |
def __init__(self, value): | |
self.value = value | |
def generate_dot_diagram(self, graph=None): | |
if not graph: |
NewerOlder