Essential Java Standard Library Classes and Methods

String Class Initializing Strings Strings can be created using literals or constructors. Using String Literals String s1 = null; String s2 = ""; String s3 = "Hello"; Using Constructors String s4 = new String(); // Empty string String s5 = new String("World"); char[] letters = {'J', 'a', 'v', 'a'}; String s6 = new ...

Posted on Thu, 09 Jul 2026 16:02:20 +0000 by Mark.P.W

JavaScript Quick Start: Objects and Built-in Objects

Objects What is an Object? In real life, everything can be considered an object—a concrete entity that is tangible and visible, such as a book, a car, or a person. Similarly, in programming, a database, a web page, or a connection to a remote server can also be regarded as an object. In JavaScript, an object is an unordered collection of relate ...

Posted on Fri, 03 Jul 2026 16:09:08 +0000 by stringfield

Essential Java API Classes for Practical Development

Mathematical Operations in Java The Math Class The Math class in Java provides various mathematical functions and constants. Here are some practical examples: package com.example.math; public class MathOperations { public static void main(String[] args) { // Mathematical constants System.out.println("Value of PI: &quot ...

Posted on Wed, 24 Jun 2026 18:20:39 +0000 by bbreslauer

Calculating Future Dates by Adding Days to Current Time in Java

Adding Days to Current Date in Java When working with date calculations in Java applications, a common requirement is to determine a future date by adding a specific number of days to the current date. This is particualrly useful in scenarios like scheduling events, calculating expiration dates, or processing time-sensitive transactions. Implem ...

Posted on Sun, 07 Jun 2026 16:45:51 +0000 by IWS

JavaScript Built-in Objects: String, Array, Date, and Math

String Object The String object in JavaScript provides various methods for manipulating text strings. Here are some commonly used properties and methods: // length property const text1 = "helloWorld"; document.write(text1.length); document.write("<br></br>"); // bold(): makes text bold const text2 = "import ...

Posted on Tue, 26 May 2026 20:15:16 +0000 by kemu_