X-Git-Url: http://nitlanguage.org diff --git a/examples/draw_operation.nit b/examples/draw_operation.nit index 2db1595..61f14eb 100644 --- a/examples/draw_operation.nit +++ b/examples/draw_operation.nit @@ -14,9 +14,42 @@ # See the License for the specific language governing permissions and # limitations under the License. -# Draws an arithmetic operation to the terminal +# Sample program which draws an arithmetic operation to the terminal +# +# Output (and input) example: +# ~~~nitish +# Left operand: 23 +# Right operand: 15 +# Operator (+, -, *, /, %): + +# Char to display: # +# Size of text: 5 +# Space between digits: 1 +# ##### ##### +# # # +# ##### ##### +# # # +# ##### ##### +# +# # ##### +# + ## # +# +++++ # ##### +# + # # +# ##### ##### +# +# __________________ +# +# ##### ##### +# # # # +# ##### ##### +# # # # +# ##### ##### +# ~~~ module draw_operation +`{ + #include +`} + redef enum Int fun n_chars: Int `{ int c;