Advertisement
Guest User

Untitled

a guest
Jul 19th, 2019
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.63 KB | None | 0 0
  1. a - Matches the string a
  2. a+b - Matches the string ab
  3. a|b - Matches either the string a and the string b
  4. a* - Matches the empty string, a, aa, aaa, aaaa, etc.
  5. (a|b)* - Matches any string of a's and b's.
  6. (a+a)* - Matches the empty string, aa, aaaa, aaaaaa, etc.
  7.  
  8. -input
  9. prefix | infix | postfix
  10. a a a
  11. -output
  12. a
  13. -input
  14. prefix | infix | postfix
  15. *a a* a*
  16. -output
  17.  
  18. a
  19. aa
  20. aaa
  21. aaaa
  22. ...
  23. -input
  24. prefix | infix | postfix
  25. *|ab (a|b)* ab|*
  26. -output
  27. a
  28. b
  29.  
  30. ab
  31. ba
  32. aa
  33. bb
  34. ...
  35. -input
  36. prefix | infix | postfix
  37. *|+a+aa+bb ((a+(a+a))|(b+b))* bb+aa+a+|*
  38.  
  39. aaa
  40. bb
  41. aaabb
  42. bbaaa
  43. aaabbaaa
  44. bbaaabb
  45. bbbbaaa
  46. ...
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement