The invention discloses a
modular programming toy set and a
programming method thereof. A
modular programming toy set, including: start program element, end program element, start element, end element, number element, character element, variable element, operation element,
logic element, execution element, end element, if element, otherwise element , otherwise if element, when element, from element, to element, step element, function start element, function return element, function name element, control car element, continuous element, output element,
infrared obstacle avoidance element, program generator, intelligent trolley. When
programming, there is only one main program, which starts with the start program element and ends the main program with the end program element. When
programming in the middle part of the program, you can use
sequential programming, conditional programming, and loop programming. If there is a function, you can use the function name component to call the function. Function programming is independent of the main program, outside the main program. After editing the program, you need to use the generate button of the program generator to generate the program.