Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
Светофор-графика
{ Светофор. } uses graphABC; const LEFT = 100; UP = 100; RIGHT = 300; DOWN = 300; procedure signal(c : color; y, t : integer); begin SetBrushColor(c); fillcircle( RIGHT div 2, y, 30); sleep(t); SetBrushColor(clWhite); fillcircle( RIGHT div 2, y, 30); end; var i, time : integer; begin time := 7; initwindow(LEFT,UP,RIGHT,DOWN); while true do begin if time in [8..24] then begin signal (clRed, DOWN div 4, 4000 ); signal (clYellow, DOWN div 2, 1000 ); signal (clGreen, 3 * DOWN div 4, 2000 ); for i := 1 to 4 do begin signal (clGreen, 3 * DOWN div 4, 500 ); signal (clWhite, 3 * DOWN div 4, 500 ); // sleep (500); end end else for i := 1 to 4 do begin signal (clYellow, DOWN div 2, 500 ); signal (clWhite, DOWN div 2, 500 ); end; time := (time + 1 ) mod 24; end end.
run
|
edit
|
history
|
help
0
practica 7 ejercicio 11
Задача №3549. Замечательные числа - 5
Урок 2 задача не из учебника: 4-значное число
practica 11 ejercicio 4
B prethodnih B sledecih
ariketa 05
день недели по номеру дня
Hello, 123
calcular_sumatoria_N
1 2