This file contains hidden or 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
import turtle | |
import random | |
snake_turtle = turtle.Pen() | |
snake_turtle.penup() | |
snake_turtle.shape('square') | |
snake_turtle.shapesize(1, 3) | |
snake_turtle.color('orange') |
This file contains hidden or 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
import turtle | |
import random | |
turtle.bgcolor('black') | |
turtle.colormode(255) | |
t = turtle.Pen() | |
t.speed('fast') | |
t.pensize(8) | |
for counter in range(500): | |
x = random.randint(-200, 200) | |
y = random.randint(-200, 200) |
This file contains hidden or 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
import random | |
lives = 9 | |
words = [ | |
'photos', | |
#'antidisestablishmentarianism', | |
'pogostick', | |
] | |
guessed_letters = [] | |
secret_word = random.choice(words) | |
clue = list(secret_word) |
This file contains hidden or 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
import random | |
import time | |
from tkinter import Tk, Canvas, HIDDEN, NORMAL | |
root = Tk() | |
root.title('Snap Game') | |
c = Canvas(root, width=400, height=400) | |
shapes = [ ] | |
circle = c.create_oval(35, 20, 365, 360, outline='black', | |
fill='black', state=HIDDEN) | |
shapes.append(circle) |
This file contains hidden or 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
import random | |
import time | |
from tkinter import Tk, Canvas | |
root = Tk() | |
root.title('Egg Catching Game') | |
c = Canvas(root, width=400, height=600, | |
background='light blue') | |
This file contains hidden or 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
<State | |
username="Samantha" | |
></State> | |
<StaticData | |
src="https://jsonplaceholder.typicode.com/users" | |
></StaticData> | |
<Script> | |
function renderCallback({ component, staticdata, state}) { | |
console.log(staticdata); | |
component.innerHTML = ` |
This file contains hidden or 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
const test = require('ava'); | |
// Deep Map - a data type that allows "deeply nested" objects that can be "sliced" into flat objects at any "level" (e.g. an object with "me.stuff" and "me.thing" keys could extract a "me" object that has "stuff" and "thing" properties) | |
function isPlainObject(obj) { | |
return obj && typeof obj === 'object' && !Array.isArray(obj); | |
} | |
class DeepMap { | |
constructor(copyFrom=null, autoSave=false) { | |
this.label = null; |
This file contains hidden or 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
"virtualenvtool" or "venvtool" | |
# config:set | |
Okay, a new standard to replace dotenv: | |
venvtool config:set THING=100 | |
This file contains hidden or 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" /> | |
<title>Add React in One Minute</title> | |
</head> | |
<body> | |
<h2>Add React in One Minute</h2> | |
<p>This page demonstrates using React with no build tooling.</p> |
This file contains hidden or 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 lang="en"> | |
<head> | |
<meta charset="utf-8"/> | |
<meta name="viewport" content="width=device-width, initial-scale=1"/> | |
<title>Scooby-dUber - Uber for Dogs</title> | |
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.1/css/bootstrap.min.css"/> | |
</head> |
NewerOlder