Obiecte Multicolore

import maya.cmds as cmdscmds.polySphere(sx=16,sy=16)for i in range(300): j=i%4+1 cmds.select(‘pSphere1.f[%d]’%i) cmds.hyperShade(assign=’blinn%d’%j) import maya.cmds as cmds cmds.polySphere(sx=40,sy=30) for i in range(1200): j=i/10%4+1 cmds.select(‘pSphere1.f[%d]’%i) cmds.hyperShade(assign=’blinn%d’%j)

Programare Roboti Lego 1

Program 1 from pybricks import ev3brick as brick from pybricks.ev3devices import (Motor, TouchSensor, ColorSensor,                                 InfraredSensor, UltrasonicSensor, GyroSensor) from pybricks.parameters import (Port, Stop, Direction, Button, Color,                                 SoundFile, ImageFile, Align) from pybricks.tools import print, wait, StopWatch from pybricks.robotics import DriveBase brick.sound.beep() dreapta=Motor(Port.A) stanga=Motor(Port.B) dreapta.run_target(200,300) stanga.run_target(200,300) Program 2 brick.sound.beep() dreapta=Motor(Port.A) stanga=Motor(Port.B) robot=DriveBase(stanga,dreapta,43.2,114) robot.drive_time(100,30,3000)