Skip to content

Commit 3139a5a

Browse files
authored
Merge pull request #4 from Saumay/formatting-changes
Formatting changes
2 parents 3291ea0 + 6c92e7f commit 3139a5a

File tree

5 files changed

+7
-7
lines changed
  • 13 - Multithreading/13.5 - Thread Priority/src
  • 17 - Stream API
    • 17.1 - Printing values using external iteration/src
    • 17.12 - 17.16 Stream Map, Reduce methods/src
  • 18 - New DateTime Api/18.1 - New DateTime Api/src
  • 9 - String + Builder + Buffer/9.3 - User input using System.in.read()/src

5 files changed

+7
-7
lines changed

13 - Multithreading/13.5 - Thread Priority/src/Test.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ public static void main(String[] args) throws InterruptedException {
2828
System.out.println("BYEEE IN BETWEEN"); // This won't be printed at the end because Main thread is idle and will execute this before only.
2929
System.out.println("Is t1 alive: " + t1.isAlive());
3030

31-
t1.join(); // will wait for t1 to complete execution and join main thread
32-
t2.join(); // will wait for t2 to complete execution and join main thread
31+
t1.join(); // will wait for t1 to complete execution and join main thread
32+
t2.join(); // will wait for t2 to complete execution and join main thread
3333
System.out.println("BYEE AT THE END");
3434

3535
System.out.println("Is t1 alive: " + t1.isAlive());

17 - Stream API/17.1 - Printing values using external iteration/src/Test.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ External Iterations (loop outside the object)
1515
- for each loop
1616
Internal Iterations (loop inside the object)
1717
- forEach method
18-
*/
18+
*/
1919

2020
import java.util.Arrays;
2121
import java.util.Iterator;

17 - Stream API/17.12 - 17.16 Stream Map, Reduce methods/src/Test.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
66
Internal Iterations: (Stream API)
77
- just focus on what to do
8-
*/
8+
*/
99

1010
import java.util.Arrays;
1111
import java.util.List;
@@ -19,8 +19,8 @@ public static void main(String[] args) {
1919

2020
// We need to find the sum of all the values*2
2121

22-
int result = 0;
2322
// 1) Using traditional for-each loop
23+
int result = 0;
2424
for (int value : values) {
2525
result += value*2;
2626
}

18 - New DateTime Api/18.1 - New DateTime Api/src/Test.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
Changes in new DateTime API:
1111
- new package time was created
1212
- Date object only print Date now, and not Time to avoid confusion
13-
*/
13+
*/
1414

1515
import java.time.Instant;
1616
import java.time.LocalDate;

9 - String + Builder + Buffer/9.3 - User input using System.in.read()/src/Test.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
- returns byte value in the form of int in range 0 to 255
77
- that value is basically the ascii value of that character
88
- not efficient
9-
*/
9+
*/
1010

1111
public class Test {
1212
public static void main(String[] args) throws Exception {

0 commit comments

Comments
 (0)