Skip to content

Jontom01/Balanced-Strings

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

48 Commits
 
 
 
 
 
 

Repository files navigation

Balanced-Strings

This program will determine whether an input string is accepted for any language that belongs to the set A. The parser is structured around the recursive descent method.

Screenshot (9)

The following is an example with c = '(' and s = ')'.

Screenshot (10)

The first command line argument contains your chosen values for c and s, written as 'cs'.

The second command line argument is your input string x, written as 'x'.

If the given string is accepted, a parse tree will be generated. The data value of the tree vertices are either one of the terminals (c or s), or <exp> if the node denotes an expression. The parse tree is printed using an implementation of pre-order traversal, which will explain the order in which each node is printed onto the screen.

About

This program will determine whether an input string is accepted for the language of balanced strings.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors