Javac's Avatar

Javac

@java-dev

- Tips and tricks for programming in Java ๐Ÿค– - Main account @asjordi.dev ๐Ÿ’ป

62
Followers
42
Following
21
Posts
23.11.2024
Joined
Posts Following

Latest posts by Javac @java-dev

Sort a Map by Value in Java

Sort a Map by Value in Java

Sort a Map by Value in #Java

20.12.2024 14:28 ๐Ÿ‘ 2 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Use properties or configuration files in an efficient and simple way in Java

Use properties or configuration files in an efficient and simple way in Java

Use properties or configuration files in an efficient and simple way in #Java

19.12.2024 17:30 ๐Ÿ‘ 1 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Safely cast long to int in Java

Safely cast long to int in Java

Safely cast long to int in #Java

18.12.2024 17:48 ๐Ÿ‘ 2 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Write and Read data from a file using RandomAccessFile in Java

Write and Read data from a file using RandomAccessFile in Java

Write and Read data from a file using RandomAccessFile in #Java
- Allows direct access to specific parts of a file
- Bidirectional reading and writing
- Working with fixed record structure files
- Modifying specific parts of a file

17.12.2024 16:45 ๐Ÿ‘ 3 ๐Ÿ” 1 ๐Ÿ’ฌ 1 ๐Ÿ“Œ 0
Write data to a file using BufferedWriter in Java

Write data to a file using BufferedWriter in Java

Write data to a file using BufferedWriter in #Java

16.12.2024 17:00 ๐Ÿ‘ 1 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Read all content from a file into a String with Java

Read all content from a file into a String with Java

Read all content from a file into a String with #Java

13.12.2024 15:10 ๐Ÿ‘ 4 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Read a file with FileInputStream in Java

Read a file with FileInputStream in Java

Read a file with FileInputStream in #Java
- Use instead if you need more control over charset.
- For large files or binary data.

12.12.2024 14:30 ๐Ÿ‘ 1 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Read all lines from a file using BufferedReader and try-with-resources in Java

Read all lines from a file using BufferedReader and try-with-resources in Java

Read all lines from a file using BufferedReader and try-with-resources in #Java

11.12.2024 16:00 ๐Ÿ‘ 2 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Read all lines from a file in one pass in Java

Read all lines from a file in one pass in Java

Read all lines from a file in one pass in #Java

- More simple, without the need of manage a buffer, but can be memory-intensive.
- Best for small to medium files.

10.12.2024 17:31 ๐Ÿ‘ 3 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Print nested array in Java

Print nested array in Java

Print nested array in #Java

09.12.2024 15:00 ๐Ÿ‘ 5 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Print an array in #Java

Print an array in #Java

Print an array in #Java

06.12.2024 17:10 ๐Ÿ‘ 1 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Calculate the sum of all elements of an int array with the Stream API in #Java

Calculate the sum of all elements of an int array with the Stream API in #Java

Calculate the sum of all elements of an integer array with the Stream API in #Java

05.12.2024 16:22 ๐Ÿ‘ 3 ๐Ÿ” 2 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Find the maximum and minimum values โ€‹โ€‹of an array using IntSummaryStatistics in #Java

Find the maximum and minimum values โ€‹โ€‹of an array using IntSummaryStatistics in #Java

Find the maximum and minimum values โ€‹โ€‹of an array using IntSummaryStatistics in #Java

- It also allows you to obtain statistics such as count, sum and average.

04.12.2024 17:00 ๐Ÿ‘ 3 ๐Ÿ” 2 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Find the maximum and minimum values of an array using API Stream in Java

Find the maximum and minimum values of an array using API Stream in Java

Find the maximum and minimum values โ€‹โ€‹of an array using API Stream in #Java

- Optionally you can use OptionalInt instead of getAsInt() to verify if the value is present or not.

03.12.2024 16:56 ๐Ÿ‘ 1 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Find the maximum and minimum values of an array using Collections.min() and Collections.max() in Java

Find the maximum and minimum values of an array using Collections.min() and Collections.max() in Java

Find the maximum and minimum values of an array using Collections.min() and Collections.max() in #Java

02.12.2024 16:00 ๐Ÿ‘ 2 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Convert a double array to list of Double in 
#Java

Convert a double array to list of Double in #Java

Convert a double array to list of Double in #Java

29.11.2024 15:35 ๐Ÿ‘ 1 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
How to sort an array of integers in Java

How to sort an array of integers in Java

How to sort an array of integers in #Java

28.11.2024 15:45 ๐Ÿ‘ 3 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Convert a int array to list of Integer in Java

Convert a int array to list of Integer in Java

Convert a int array to list of Integer in #Java

27.11.2024 15:55 ๐Ÿ‘ 1 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Convert a String array to a list of strings in Java

Convert a String array to a list of strings in Java

Convert a String array to a list of strings in #Java

26.11.2024 16:00 ๐Ÿ‘ 2 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Reverse a String in Java

Reverse a String in Java

Reverse a String in #Java

25.11.2024 15:30 ๐Ÿ‘ 2 ๐Ÿ” 1 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0

System.out.println("Hello World!")

23.11.2024 23:58 ๐Ÿ‘ 1 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0