原创 python-if語句

if語句 判斷一個數是奇數還是偶數: x=int(input()) if x%2==0: print("even") else : print("odd") x=int(input()) y=1 if x%2==

原创 manim-3D場景

設置角度 class CameraPosition4(ThreeDScene): def construct(self): axes = ThreeDAxes() circle=Circle

原创 python-轉換內置函數

轉換內置函數: bool() int() float() complex() str() ord() chr() bin() oct() hex() list() >>> list('abcd') ['a', 'b', 'c',

原创 python-數字類型

整數不同進製表示 二進制: 前導符:0b 或 0B 示例: 0b10 表示十進制的2 八進制: 前導符: 0o或0O 示例: 0o10表示十進制的8 十六進制: 前導符: 0x或0X 示例:0x10表示十進制的16 科學計數法:

原创 manim-利用循環創建對象

class example(Scene): def construct(self): text_list=[] text_group=VGroup() for i in ra

原创 manim-arrange_submobjects的應用及LaggedStart的應用

這是example_scenes.py中的代碼 class example(Scene): def construct(self): title = TextMobject("This is some \\

原创 python-字符串

單引號、雙引號、三引號: >>> "i'm sam" "i'm sam" >>> '"you are welcome", tom said' '"you are welcome", tom said' >>> '''first r

原创 manim-TextMobject 換行

manim-TextMobject 換行 在需要換行的地方插入"\\\"即可。 class example(Scene): def construct(self): text=TextMobject('Th

原创 座標系旋轉後的點座標、座標點旋轉後的點座標

座標系旋轉後的點座標、座標點旋轉後的點座標 1. 座標系旋轉後的點座標 2. 座標點旋轉後的點座標