- 数字
let n1: f32 = 1.0f32;
let n2: isize = 0xF1A; // 16進数
let n3: isize = 0b11001; // 2進数
#coding:utf-8 | |
import psutil | |
from mpl_toolkits.mplot3d import Axes3D | |
import numpy as np | |
import matplotlib.pyplot as plt | |
import matplotlib.animation as animation | |
TIME_NUM = 90 | |
FRAMES = 360 |
import itertools | |
stars = [] | |
class Point: | |
def __init__(self, x, y): | |
self.x = x | |
self.y = y | |
#!/usr/bin/env python3 | |
import sys | |
from http.server import ( | |
SimpleHTTPRequestHandler, | |
HTTPServer, | |
test, | |
) |
def draw_branch(branch_len, direction): | |
pushMatrix() | |
rotate(direction * PI / 3) | |
line(0, 0, branch_len, 0) | |
popMatrix() | |
def setup(): | |
size(500, 500) | |
background(30, 30, 255) | |
strokeCap(ROUND) |