small but useful codes