I am a newbie to this field so I apologize in advance if this seems trivial.
Say I have written some code in
Solidity, for instance something like the quick sort code (https://gist.github.com/subhodi/b3b86cc13ad2636420963e692a4d896f).
Now I want to locally run it with my
evm virtual machine (due to certain reason, we prefer to run it locally with virtual machine, instead of using some web services...), so I would use commands like:
solc --bin --optimize -o . qs.sol ./evm --debug --code $(cat QuickSort.bin) run
So after executing the above commands, I do see some logs printed out; however, I am still unclear about:
How exactly can I specify a function to execute? In the above quick sort case I only have one "public" function, but what if I have many?
How to pass in parameters into the
evmwhen executing certain functions?
Is there any convenient way I can expect to read some output? For instance can
evmreturn a sorted array and somehow print it out, or write into some log files?