Haskell Calculator Code
Brought to you by:
ctraut
File | Date | Author | Commit |
---|---|---|---|
COPYING | 2011-01-22 | ctraut | [r6] Added a README and COPYING file. |
README | 2011-01-22 | ctraut | [r6] Added a README and COPYING file. |
calculator.hs | 2012-01-19 | ctraut | [r8] Fixed an awkward typo in the source code... :P |
main.hs | 2011-01-21 | ctraut | [r4] Added a makefile to simplify compilation. makef... |
makefile | 2011-01-24 | ctraut | [r7] Some cleaning up! |
unit_test.hs | 2012-01-19 | ctraut | [r8] Fixed an awkward typo in the source code... :P |
-------------------------------------------------------------------------------- -- Licence A little Haskell based calculator that evaluates a mathematical expression. Copyright (C) 2011 Christoph Traut This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>. -------------------------------------------------------------------------------- -- Project Description A small command-line calculator, written in Haskell, that takes input like "14+(12+24)/(8.5-2.5)" and prints out the result. It's nothing special really, just a little project I did to learn Haskell. -------------------------------------------------------------------------------- -- Project Page https://sourceforge.net/projects/haskellcalc/ -------------------------------------------------------------------------------- -- Info The calculator is still work in progress and as I learn more about Haskell and whenever I find some free time, I will come back to it to clean up the code, or add features to it. Bug reports, or feedback of any kind, are very much appreciated. -------------------------------------------------------------------------------- -- Installation Instructions I don't provide any binary packages for this software, you will have to compile it yourself. There is a makefile packaged that should make this trivial. But it requires you to have make and ghc installed on your system. You can use "make test" to compile and run the unit tests for the calculator. If you can't compile via makefile, this command should be enough: ghc calculator.hs main.hs