Article View: comp.lang.pascal.misc
Article #41Re: Writing an expression evaluator
From: Malcolm Smith
Date: Fri, 16 Feb 1996 06:56
Date: Fri, 16 Feb 1996 06:56
24 lines
1245 bytes
1245 bytes
Aristotle <johndc@cnj.digex.net> wrote: > > Does anyone have any tips on how to go about writing an expression > evaluator(one complex enough to handle Trig. functions). I am writing a > program that uses expression and I would like to have the user be able to > enter their own expressions and have my program implement them. Any help > would be appreciated. Thanks in advance! > > John M. "Aristotle" De Cristofaro I have an expression evaluator written in C based on Polish notation. It was primarily designed for normal mathemtical functions such as add, subtract, multiply and divide. It does, however, manager brackets - using recursion. It could be modified to include further functions. Email me if you want the source code. Malcolm Smith mjsmith@mpx.com.au
Technical Details
Message-ID:
<4g19rq$288@inferno.mpx.com.au>Path:
arc1-ca.pugleaf.net!inferno.mpx.com.au!newsReferences:
<311FEBD8.7305@cnj.digex.net>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!inferno.mpx.com.au!news From: Malcolm Smith <mjsmith@mpx.com.au> Newsgroups: comp.lang.pascal.misc,comp.lang.pascal.borland,comp.programming,comp.lang.misc,comp.lang.c,comp.lang.c++ Subject: Re: Writing an expression evaluator Date: 16 Feb 1996 06:56:58 GMT Organization: Microplex Pty Ltd Message-ID: <4g19rq$288@inferno.mpx.com.au> References: <311FEBD8.7305@cnj.digex.net> NNTP-Posting-Host: dialup-211.mpx.com.au