Skip to content
This repository has been archived by the owner on Aug 5, 2023. It is now read-only.

Commit

Permalink
Addieren von großen Preisen
Browse files Browse the repository at this point in the history
  • Loading branch information
axelerator committed Jun 28, 2015
1 parent 9a40d3d commit 773ee90
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions DerPreisIstHeiss.java
Expand Up @@ -22,8 +22,8 @@ public boolean equals(Object other) {

public static void main(String[] args) {

Price p1 = new Price(23.0f);
Price p2 = new Price(23.0f);
Price p1 = new Price(230000.01f);
Price p2 = new Price(230000.01f);

float amountSum = p1.amount + p2.amount
Price p3 = new Price(amountSum);
Expand Down
6 changes: 3 additions & 3 deletions README.md
Expand Up @@ -23,8 +23,8 @@ class DerPreisIstHeiss {

public static void main(String[] args) {

Price p1 = new Price(23.0f);
Price p2 = new Price(23.0f);
Price p1 = new Price(230000.01f);
Price p2 = new Price(230000.01f);

Price p3 = new Price(p1.amount + p2.amount);
System.out.println(p3);
Expand All @@ -34,4 +34,4 @@ class DerPreisIstHeiss {
```
Ausgabe:
========
46.0
460000.03

0 comments on commit 773ee90

Please sign in to comment.