# Parsing Expression Grammar for a simple calculator program.

Exp "expression" <- Term (AddOp Term)*

Term "term" <- Factor (MulOp Factor)*

Factor "factor" <- Number / Group

Number "number" <- [0-9]+ Spacing

Group "parentheses" <- OpenParen Exp CloseParen

AddOp "addition or subtraction" <- ("+" / "-") Spacing

MulOp "multiplication or division" <- ("*" / "/") Spacing

OpenParen <- "(" Spacing

CloseParen <- ")" Spacing

Spacing "whitespace" <- " "*
