
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Samual Sam has Published 2310 Articles

Samual Sam
2K+ Views
To check for Long overflow, we need to check the Long.MAX_VALUE with the multiplied long result, Here, Long.MAX_VALUE is the maximum value of the Long type in Java. Let us see an example wherein long values are multiplied and if the result is more than the Long.MAX_VALUE, then an exception ... Read More

Samual Sam
2K+ Views
In this article, we will learn to list up the short month names in Java. To do so we will be using DateFormatSymbols class from java.text package. java.text: This package offers classes and interfaces for managing text, dates, numbers, and messages in a way that is not dependent on any specific ... Read More

Samual Sam
2K+ Views
Introduction In this article, we'll explore how to check whether a given string contains only digits or a mix of digits and other characters in Java. We'll achieve this by using the String class and its matches() method. Problem Statement Given a string write a Java program to check ... Read More

Samual Sam
2K+ Views
In this article, we will discuss how to get the operating system name and version in Java. To get the name and version of the operating system we will be using the System.getProperty() method. Steps to get the operating system name and version The following are the steps to get the operating ... Read More

Samual Sam
2K+ Views
In this article, we will learn to subtract a year from the current date using Java. We will be using the Calender class of java.util package. Calendar class in Java is an abstract class that provides different methods to convert between a specific instant in time and a set of ... Read More

Samual Sam
2K+ Views
In this article, we will learn how to retrieve the highest key stored in a TreeMap. We will create a simple Java program that demonstrates how to create a TreeMap, add key-value pairs to it, and then use the lastKey() method to find the highest key in the map. ... Read More

Samual Sam
3K+ Views
In this article, we will demonstrate how to calculate the difference in milliseconds between two Instant objects using the ChronoUnit class. It shows how to work with time-based classes in the java.time package, specifically focusing on creating and manipulating time instants and calculating durations between them. ChronoUnit: A standard set of ... Read More

Samual Sam
2K+ Views
In this article, we will learn to sort a short array in Java using the Arrays.sort() method. Begin by declaring and initializing an unsorted short array, then sort it and display the sorted array. Arrays.sort() method : This method sorts the elements of array in ascending order which have specified ... Read More

Samual Sam
3K+ Views
The GregorianCalendar class in Java allows us to manipulate dates and times easily. In this example, we will create a GregorianCalendar object and use it to display the current date and the date of the previous month. Problem Statement Write a Java program and create a GregorianCalendar object, display the ... Read More

Samual Sam
4K+ Views
The factorial of a number is a fundamental concept in mathematics, representing the product of all positive integers up to that number. Calculating the factorial of a given number is a common problem in programming, and Java provides a straightforward way to achieve this using a while loop. ... Read More