@@ -57,12 +57,12 @@ Looking at the tests in AppTest.java might help you see how these methods will b
...
@@ -57,12 +57,12 @@ Looking at the tests in AppTest.java might help you see how these methods will b
`toString()` should return a string in the format `a + jb` where `a` is the real component and `b` is the imaginary component. Note the rules below should be followed.
`toString()` should return a string in the format `a + jb` where `a` is the real component and `b` is the imaginary component. Note the rules below should be followed.
|Real Part|Imaginary Part|String|
|Real Part|Imaginary Part|String|
|---|---|---|
|--- |--- | --- |
|`2.6`|`5.2`|`2.6 + j5.6`|
|`2.6` |`5.2`|`2.6 + j5.6`|
|`2.6`|`0`|`2.6`|
|`2.6` |`0` |`2.6`|
|`0`|`5.2`|`j5.2`|
|`0` |`5.2` |`j5.2`|
|`2.6`|`-9.8`|`2.6 - j9.8`|
|`2.6` |`-9.8`|`2.6 - j9.8`|
If the real or imaginary part is 0 it should not be shown. If the imaginary part is negative the negative symbol should be before the j not the number (i.e. `4.3 - j2.1` not `4.3 + j-2.1`).
If the real or imaginary part is 0 it should not be shown. If the imaginary part is negative the negative symbol should be before the j not the number (i.e. `4.3 - j2.1` not `4.3 + j-2.1`).
@@ -57,12 +57,12 @@ Looking at the tests in AppTest.java might help you see how these methods will b
...
@@ -57,12 +57,12 @@ Looking at the tests in AppTest.java might help you see how these methods will b
`toString()` should return a string in the format `a + jb` where `a` is the real component and `b` is the imaginary component. Note the rules below should be followed.
`toString()` should return a string in the format `a + jb` where `a` is the real component and `b` is the imaginary component. Note the rules below should be followed.
|Real Part|Imaginary Part|String|
|Real Part|Imaginary Part|String|
|---|---|---|
|--- |--- | --- |
|`2.6`|`5.2`|`2.6 + j5.6`|
|`2.6` |`5.2`|`2.6 + j5.6`|
|`2.6`|`0`|`2.6`|
|`2.6` |`0` |`2.6`|
|`0`|`5.2`|`j5.2`|
|`0` |`5.2` |`j5.2`|
|`2.6`|`-9.8`|`2.6 - j9.8`|
|`2.6` |`-9.8`|`2.6 - j9.8`|
If the real or imaginary part is 0 it should not be shown. If the imaginary part is negative the negative symbol should be before the j not the number (i.e. `4.3 - j2.1` not `4.3 + j-2.1`).
If the real or imaginary part is 0 it should not be shown. If the imaginary part is negative the negative symbol should be before the j not the number (i.e. `4.3 - j2.1` not `4.3 + j-2.1`).