Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Windows PowerShell
- Copyright (C) Microsoft Corporation. All rights reserved.
- PS C:\Users\rschubert> cd "c:\Users\rschubert\Documents\dev\" ; if ($?) { javac Polygon.java } ; if ($?) { java Polygon }
- Welcome to the Polygonal Property Calculator
- Enter your first name: Barry
- Enter your last name: Wittman
- Enter the sides the property has: 7
- Enter the side length in meters: 10.4
- Enter property cost per square meter: $3.50
- Enter fence cost per meter: $6.75
- Property Information for B. Wittman
- ****************************************************************
- Total area: 393.044 square meters
- Total perimeter: 72.800 meters
- Length of apothem: 10.798 meters
- Interior angle: 128.571 degrees
- Cost of land: $1375.65
- Cost of fencing: $491.40
- Total cost: $1867.05
- Loan Information
- ****************************************************************
- Enter annual interest rate: .05
- Enter length of loan in years: 10
- Total cost with interest: $3041.23
- PS C:\Users\rschubert\Documents\dev> cd "c:\Users\rschubert\Documents\dev\" ; if ($?) { javac Polygon.java } ; if ($?) { java Polygon }
- Welcome to the Polygonal Property Calculator
- Enter your first name: 19993
- Enter your last name: 48ugb38rarq99999999999999999999999999999999999999999999999999999999
- Enter the sides the property has: g
- Exception in thread "main" java.util.InputMismatchException
- at java.base/java.util.Scanner.throwFor(Scanner.java:939)
- at java.base/java.util.Scanner.next(Scanner.java:1594)
- at java.base/java.util.Scanner.nextInt(Scanner.java:2258)
- at java.base/java.util.Scanner.nextInt(Scanner.java:2212)
- at Polygon.main(Polygon.java:16)
- PS C:\Users\rschubert\Documents\dev> cd "c:\Users\rschubert\Documents\dev\" ; if ($?) { javac Polygon.java } ; if ($?) { java Polygon }
- Welcome to the Polygonal Property Calculator
- Enter your first name: f
- Enter your last name: g
- Enter the sides the property has: -2
- Enter the side length in meters: 3333333.41323123123323
- Enter property cost per square meter: $-13
- Enter fence cost per meter: $11
- Property Information for f. g
- ****************************************************************
- Total area: 0.000 square meters
- Total perimeter: -6666666.826 meters
- Length of apothem: -0.000 meters
- Interior angle: 360.000 degrees
- Cost of land: $-0.00
- Cost of fencing: $-73333335.09
- Total cost: $-73333335.10
- Loan Information
- ****************************************************************
- Enter annual interest rate: 0
- Enter length of loan in years: 0
- Total cost with interest: $-73333335.10
- PS C:\Users\rschubert\Documents\dev> cd "c:\Users\rschubert\Documents\dev\" ; if ($?) { javac Polygon.java } ; if ($?) { java Polygon }
- Welcome to the Polygonal Property Calculator
- Enter your first name: 0
- Enter your last name: 0
- Enter the sides the property has: 0
- Enter the side length in meters:
- 0
- Enter property cost per square meter: $0
- Enter fence cost per meter: $0
- Property Information for 0. 0
- ****************************************************************
- Total area: NaN square meters
- Total perimeter: 0.000 meters
- Length of apothem: NaN meters
- Interior angle: -Infinity degrees
- Cost of land: $NaN
- Cost of fencing: $0.00
- Total cost: $NaN
- Loan Information
- ****************************************************************
- Enter annual interest rate: 0
- Enter length of loan in years: 0
- Total cost with interest: $NaN
- PS C:\Users\rschubert\Documents\dev> 0
- 0
- PS C:\Users\rschubert\Documents\dev> 0
- 0
- PS C:\Users\rschubert\Documents\dev> 0
- 0
- PS C:\Users\rschubert\Documents\dev> cd "c:\Users\rschubert\Documents\dev\" ; if ($?) { javac Polygon.java } ; if ($?) { java Polygon }
- Welcome to the Polygonal Property Calculator
- Enter your first name: 1/2
- Enter your last name: 1/2
- Enter the sides the property has: 1/2
- Exception in thread "main" java.util.InputMismatchException
- at java.base/java.util.Scanner.throwFor(Scanner.java:939)
- at java.base/java.util.Scanner.next(Scanner.java:1594)
- at java.base/java.util.Scanner.nextInt(Scanner.java:2258)
- at java.base/java.util.Scanner.nextInt(Scanner.java:2212)
- at Polygon.main(Polygon.java:16)
- PS C:\Users\rschubert\Documents\dev>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement