-
Book Overview & Buying
-
Table Of Contents
Microsoft Visual C++ Windows Applications by Example
By :
The core of a spreadsheet program is its ability to interpret formulas. When the user inputs a formula in a cell, it has to be interpreted and its value has to be evaluated. The process is called formula interpretation, and is divided into three separate steps. First, given the input string, the scanner generates a list of tokens, then the parser generates a syntax tree, and, finally, the evaluator determines the value of the formula.

A token is the smallest significant part of the formula. For instance, the text "a1" is interpreted as a token representing a reference, the text "1.2" is interpreted as the value 1.2. Assume that the cells have values according the sheet below, the formula interpretation process will be as follows.




The scanner takes a string as input, traverses it, and finds its least significant parts, its tokens. Blanks are ignored, and the scanner sees no difference between capital and small letters. The token T_VALUE needs an extra piece...
Change the font size
Change margin width
Change background colour