Skip to content

Simple interpreter for the pseudocode langauge used to teach programming in Romanian high schools, made in Rust.

License

Notifications You must be signed in to change notification settings

Gungy2/pseudocod

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Pseudocod Rust

Simple interpreter for the pseudocode langauge used to teach programming in Romanian high schools. It is made entirely in Rust, using the Nom parser.

Usage

In order to run the interpreter with a file, execute the command:

cargo run -- filename

Example of pseudocode

scrie 'Introduceti n:'
citeste n
daca n = 0 atunci
  scrie 'fib(', n, ') = ', 0
altfel
  daca n = 1 atunci
    scrie 'fib(', n, ') = ', 1
  altfel
    x <- 0
    y <- 1
    pentru i <- 0, n - 2 executa
      tmp <- x
      x <- y
      y <- tmp + x
    scrie 'fib(', n, ') = ', y

Using it for teaching

If you are a teacher that wants to use the tool, feel free to contact me and I will do my best to add any features that you feel are missing!

About

Simple interpreter for the pseudocode langauge used to teach programming in Romanian high schools, made in Rust.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages