tripl.1 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. .TH TRIPL 1 "26 Dec 21"
  2. .SH NAME
  3. tripl \- the interpreter of the tripl programming language.
  4. .SH SYNOPSIS
  5. \fBtripl\fP [ FILE ]
  6. .SH DESCRIPTION
  7. \fBtripl\fP is a programming language that uses different
  8. characters to do different things. You can use tripl to calculate
  9. the sum of two numbers, print out messages and other things interesting.
  10. .SH LICENSE
  11. \fBtripl\fP is distrubuted under the GNU General Public License. See the
  12. \fBLICENSE\fP file in the source directory of tripl. Of course, you need
  13. to download that from https://gitee.com/pengruiyang-cpu/tripl.git before
  14. that.
  15. .SH SYNTAX
  16. \fB$\fP: uses to push a number into stack.
  17. eg. \fB$ 1048576\fP
  18. \fB$ -1048576\fP
  19. \fB$ 0\fP
  20. \fB#\fP: line comment
  21. \fB+\fP: addition. This will add the numbers of the top stack (pop them
  22. out) and push the result into stack.
  23. \fB!\fP: stack dump. This dumps the stack, you can see numbers in the stack,
  24. but this won't change anything.
  25. \fB~\fP: print out message. This prints a message:
  26. eg. \fB~ hello, world\fP
  27. \fB~ hello, world\\n\fP
  28. \fB:\fP: print a number.
  29. eg. \fB: 1\fP : prints stack[0] as number
  30. \fB: 2\fP : prints stack[1] as number