Author: Mohtashim Nawaz
- 29 November
How to Get Variable From Another Class in Java
In this article, you will learn about accessing a variable from another class in a Java Program. To be able to program in any programming language, it is very critical to be able to understand how to use the variables according to your need, and thus it makes it very important to be able to […]
- 20 September
Return ArrayList in Java
This article discusses cases of returning an ArrayList in Java from a method. An ArrayList in Java is a collection of elements of the same data type under a single variable name. In different cases, you can return an ArrayList from a method in Java. These cases are as given below. Returning ArrayList from a […]
- 16 September
How to Take Integer Input in Java
This article discusses the methods to take the integer input in Java. Variables In programs, data values are reserved in memory locations that can be identified by names (identifiers). Such named memory location which temporarily reserves data that can be changed while the program is running is called a variable. Let’s see how variables are […]
- 11 June
Remove Parentheses From String in Java
Java uses the Strings data structure to store the text data. This article discusses methods to remove parentheses from a String in Java. Java Strings Java Strings is a class that stores the text data at contiguous memory locations. The String class implements the CharSequence interface along with other interfaces. Strings are a constant data […]
- 18 May
Fill Array With Random Numbers in Java
The arrays are a commonly used data structure that stores the data in contiguous memory. In this article, you will understand different methods to fill the array with random numbers in Java. We will generate the random numbers using different library methods such as the Java Utility library’s Random class, the Java’s Math class, and […]
- 18 May
How to Sum BigDecimal Using Stream in Java
This article discusses how to sum BigDecimal using stream. One of the significant features in Java 8 is the introduction of stream functionality and a way of carrying out the sum operation on streams of numbers like BigDecimal. BigDecimal objects are immutable like String. Once immutable objects are created they can not be modified. So […]
- 18 May
SAX Error – Content Is Not Allowed in Prolog
This article discusses the SAX Error – Content is not allowed in prolog. The SAX parser is the XML parsing API that you can use to process the XML files. However, while using the SAX parser, you may encounter SAX error – content is not allowed in prolog. Sax Error Due to Invalid Text Before […]
- 18 May
Return True in Java
This article discusses the methods to return true in Java. The article discusses general approach to return a boolean variable from a function in Java. Boolean Values in Java The boolean values in Java represent a truth or fallacy. To denote the truth boolean true is used while boolean false denotes the fallacy. You should […]
- 17 May
How to Add Multiple Values for Single Key In HashMap in Java
This article discusses the HashMap in Java and how to add multiple values for Single Key In HashMap in Java. HashMap The HashMap in Java is an instrument that allows efficient access, insertion, deletion, and updating using the indexing concept by storing data in the form of key and value pairs. It was introduced in […]