I hereby claim:
- I am fohlin on github.
- I am fohlin (https://keybase.io/fohlin) on keybase.
- I have a public key ASACLpse4FVfa6ARM1frmqj5V1jpm-_4507R3VfMjE_U1go
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
| items = ['a', 'b', 'c'] | |
| # A | |
| for x in items: | |
| print(x) | |
| # B | |
| my_iterator = iter(items) | |
| for y in my_iterator: | |
| print(y) |
| const caniuse = require('caniuse-api'); | |
| const featureSupport = {}; | |
| const features = [ | |
| 'classlist', | |
| 'element-closest', | |
| 'es6-module', | |
| 'es6-class', | |
| 'fetch', | |
| 'promises', |
| var httpProxy = require('http-proxy'); | |
| var proxy = httpProxy.createProxyServer({target:'http://localhost:3000'}); | |
| proxy.on('proxyReq', function(proxyReq, req, res, options) { | |
| console.info(req); | |
| res.setHeader('X-Special-Proxy-Header', 'foobar'); | |
| proxyReq.setHeader('X-Special-Proxy-Header', 'foobar'); | |
| }); |
Ladda hem DrJava som JAR-fil och kör med senaste versionen av Java JDK. Gör så här:
jdk-8u111-macosx-x64.dmg.Kör denna fil och följ instruktionerna.
| ''' | |
| @author Michael J Bommarito II | |
| @date Feb 26, 2011 | |
| @license Simplified BSD, (C) 2011. | |
| This script demonstrates how to use Python to archive historical tweets. | |
| ''' | |
| import codecs | |
| import csv |
| import re | |
| from django import forms | |
| from django.contrib.auth.models import User | |
| from django.contrib.auth.forms import UserCreationForm | |
| class UniqueUserEmailField(forms.EmailField): | |
| """ | |
| An EmailField which only is valid if no User has that email. | |
| """ | |
| def validate(self, value): |
| # Using the OS X "say" command to demo inheritance | |
| # Thanks to Simon Willison for inspiration: http://gist.github.com/267147 | |
| import subprocess | |
| def say(s): | |
| subprocess.call(['say', str(s)]) | |
| class SpeakingList(list): | |
| """This custom list speaks (if you're on OS X). Amazing!""" |