mirror of
https://github.com/3b1b/manim.git
synced 2025-07-30 21:44:19 +08:00
Refactored scene
This commit is contained in:
@ -11,6 +11,12 @@ import re
|
||||
|
||||
from constants import *
|
||||
|
||||
def list_update(l1, l2):
|
||||
return filter(lambda e : e not in l2, l1) + l2
|
||||
|
||||
def all_elements_are_instances(iterable, Class):
|
||||
return all(map(lambda e : isinstance(e, Class), iterable))
|
||||
|
||||
def adjascent_pairs(objects):
|
||||
return zip(objects, list(objects[1:])+[objects[0]])
|
||||
|
||||
|
Reference in New Issue
Block a user