summaryrefslogtreecommitdiffstats
path: root/Aufgabe6
diff options
context:
space:
mode:
authorStefan Suhren <suhren.stefan@fh-swf.de>2015-12-17 20:41:36 +0100
committerStefan Suhren <suhren.stefan@fh-swf.de>2015-12-17 20:42:10 +0100
commit6e588e7e9d9ed4da30c0240b016b33d577b9ea50 (patch)
tree0d72ac95aa89652fb3eda780b0a329b8ee3b9ab3 /Aufgabe6
parentc76dfcd447c293b6937913ab9cf665a2351e55f0 (diff)
downloadSkriptsprachen-6e588e7e9d9ed4da30c0240b016b33d577b9ea50.tar.gz
Skriptsprachen-6e588e7e9d9ed4da30c0240b016b33d577b9ea50.zip
Update documentation
Diffstat (limited to 'Aufgabe6')
-rw-r--r--Aufgabe6/RPN/Changes5
-rw-r--r--Aufgabe6/RPN/README18
-rw-r--r--Aufgabe6/RPN/lib/RPN.pm35
3 files changed, 26 insertions, 32 deletions
diff --git a/Aufgabe6/RPN/Changes b/Aufgabe6/RPN/Changes
index 4e5cfcf..304598e 100644
--- a/Aufgabe6/RPN/Changes
+++ b/Aufgabe6/RPN/Changes
@@ -1,5 +1,10 @@
Revision history for Perl extension RPN.
+1.0 Thu Dec 17 20:30:00 2015
+ - Implement and test RPN functionality
+ - Add documentation
+ - Add README descriptions
+
0.01 Thu Dec 17 17:14:28 2015
- original version; created by h2xs 1.23 with options
-XA -n RPN
diff --git a/Aufgabe6/RPN/README b/Aufgabe6/RPN/README
index 026594d..df1a08c 100644
--- a/Aufgabe6/RPN/README
+++ b/Aufgabe6/RPN/README
@@ -1,16 +1,7 @@
-RPN version 0.01
+RPN version 1.0
================
-The README is used to introduce the module and provide instructions on
-how to install the module, any machine dependencies it may have (for
-example C compilers and installed libraries) and any other information
-that should be provided before the module is installed.
-
-A README file is required for CPAN modules since CPAN extracts the
-README file from a module distribution so that people browsing the
-archive can use it get an idea of the modules uses. It is usually a
-good idea to provide version information here so that people can
-decide whether fixes for the module are worth downloading.
+This module makes it possible to calculate in reverse polish notation.
INSTALLATION
@@ -25,16 +16,13 @@ DEPENDENCIES
This module requires these other modules and libraries:
- blah blah blah
+ Math::Trig
COPYRIGHT AND LICENCE
-Put the correct copyright and licence information here.
-
Copyright (C) 2015 by Stefan Suhren
This library is free software; you can redistribute it and/or modify
it under the same terms as Perl itself, either Perl version 5.22.0 or,
at your option, any later version of Perl 5 you may have available.
-
diff --git a/Aufgabe6/RPN/lib/RPN.pm b/Aufgabe6/RPN/lib/RPN.pm
index 693ca51..6e8f5b1 100644
--- a/Aufgabe6/RPN/lib/RPN.pm
+++ b/Aufgabe6/RPN/lib/RPN.pm
@@ -391,41 +391,43 @@ sub rpn {
1;
__END__
-# Below is stub documentation for your module. You'd better edit it!
+# Below is the documentation for RPN.
=head1 NAME
-RPN - Perl extension for blah blah blah
+RPN - Perl extension that implements simple RPN functionality.
=head1 SYNOPSIS
use RPN;
- blah blah blah
+
+ RPN::rpn("5 5 +");
=head1 DESCRIPTION
-Stub documentation for RPN, created by h2xs. It looks like the
-author of the extension was negligent enough to leave the stub
-unedited.
+This module makes it possible to calculate in reverse polish notation.
-Blah blah blah.
+=over 1
-=head2 EXPORT
+=item rpn()
-None by default.
+This is the evaluation function for an RPN string.
+Input:
+ $rpnString - The String with an RPN expression.
+Output:
+ undef if an error occured otherwise the result of the upn evaluation.
-=head1 SEE ALSO
+=back
-Mention other useful documentation such as the documentation of
-related modules or operating system documentation (such as man pages
-in UNIX), or any relevant external documentation such as RFCs or
-standards.
+=head2 EXPORT
-If you have a mailing list set up for your module, mention it here.
+None by default.
+
+=head1 SEE ALSO
-If you have a web site set up for your module, mention it here.
+https://en.wikipedia.org/wiki/Reverse_Polish_notation
=head1 AUTHOR
@@ -439,5 +441,4 @@ This library is free software; you can redistribute it and/or modify
it under the same terms as Perl itself, either Perl version 5.22.0 or,
at your option, any later version of Perl 5 you may have available.
-
=cut