Skip to content

Latest commit

 

History

History

hello-world

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 

Hello world example

This example shows how to print the text "hello" to the screen using surround. The process consists of defining the operation in the estimate() method of Main. The object being processed is an instance of AssemblerState, which inherits from State. The surround object is initialised with only one stage as assembler = Assembler(data, HelloValidator(), HelloWorld()], and the line assembler.run() calls the estimate() method of HelloWorld, using a new instance of AssemblerState as a parameter. Finally, the content of the AssemblerState object is printed to screen.

Run

From surround's root folder, run

python3 examples/hello-world/main.py

Or from the project's local folder:

python3 main.py