Ruang penulis
SEBUAH JURNAL TENTANG TEKNOLOGI

Belajar hal baru.
Tulis. Bagikan.

Ruang untuk merangkai pengetahuan, satu baris kode setiap hari.
Temukan tutorial, ide, dan catatan dari perjalanan belajar.

1914 catatan & terus bertumbuh
PILIHAN EDITOR
Java

Memahami Java Stream: olah koleksi dengan lebih ringkas

Pelajari alur filter, map, dan collect untuk mengolah data Java dengan kode yang mudah dibaca.

D Tim Diary Coding · 1 menit baca
UNTUK RASA INGIN TAHUMU

Catatan terbaru.

CORE API / CATATAN</>
Core API24 Feb 2006

How do I get the current month name?

To get the current month name from the system we can use java.util.Calendar class. The Calendar.get(Calendar.MONTH) returns the month value as an integer starting from 0 as the first month and 11 as the last month. This mean January equals to 0, February equals to 1 and December equals to 11. Let’s see the code […]

Wayan · 2 menit baca
CORE API / CATATAN</>
Core API20 Feb 2006

How do I check if a string is a valid number?

When building a computer program we will use a lot of string to represent our data. The data might not just information about our customer name, email or address, but will also contain numeric data represented as string. So how do we know if this string contains a valid number? Java provides some wrappers to […]

Wayan · 2 menit baca
CORE API / CATATAN</>
Core API19 Feb 2006

How do I get date, month, year values from the current date?

What date, month, year, day-of-week, day-of-month, day-of-year is it today? If we want to answer these question we can use java.util.Calendar and java.util.GregorianCalendar which is the implementation of Calendar abstract class. These classes can help us to get integer value such as date, month, year from a Date object. Let’s see the example code. package […]

Wayan · 2 menit baca
CORE API / CATATAN</>
Core API18 Feb 2006

How do I get the minimum and maximum value of a primitive data types?

To get the minimum or maximum value of a primitive data types such as byte, short, int, long, float and double we can use the wrapper class provided for each of them, the wrapper classes are Byte, Short, Integer, Long, Float and Double which is located in java.lang package. package org.kodejava.lang; public class MinMaxExample { […]

Wayan · 2 menit baca
CORE API / CATATAN</>
Core API17 Feb 2006

How do I convert String into Date Object in Java?

The following code shows how we can convert a string representation of date into java.util.Date object. To convert a string of date we can use the help from java.text.SimpleDateFormat that extends java.text.DateFormat abstract class. package org.kodejava.text; import java.text.DateFormat; import java.text.ParseException; import java.text.SimpleDateFormat; import java.time.LocalDate; import java.time.format.DateTimeFormatter; import java.util.Date; public class ConvertStringTo...

Wayan · 2 menit baca
CORE API / CATATAN</>
Core API13 Feb 2006

How do I compare if two arrays are equal?

Using Arrays.equals() methods we can compare if two arrays are equal. Two arrays are considered to be equal if their length, each element in both arrays are equal and in the same order to one another. package org.kodejava.util; import java.util.Arrays; public class CompareArrayExample { public static void main(String[] args) { String[] abc = {"Kode", "Java", […]

Wayan · 1 menit baca

Pengetahuan tumbuh ketika dibagikan.

Simpan rasa ingin tahu. Selalu ada hal baru untuk dipelajari.

Jelajahi catatan ↗
Putu Adi Guna Permana
TENTANG PENULIS

Dr (C). Ir. Putu Adi Guna Permana, S.Kom., M.Kom., IPM., ASEAN Eng.

Penulis dan pendiri Diary Coding — berbagi catatan, tutorial, dan pengalaman seputar pemrograman untuk siapa pun yang ingin terus belajar.