Shriansh Kumar has Published 324 Articles

Scanner and nextChar() in Java

Shriansh Kumar

Shriansh Kumar

Updated on 05-May-2023 17:59:18

5K+ Views

Scanner is a class available in ‘java.util’ package used to take input from numerous sources like a file, or console. The most common source of taking input is from standard input i.e. keyboard. The scanner class has few methods to take input of primitives and strings from the keyboard. We ... Read More

String Arrays in Java

Shriansh Kumar

Shriansh Kumar

Updated on 05-May-2023 17:57:50

1K+ Views

String and Arrays are two distinct things. Array is a linear data structure that is used to store group of elements with similar datatypes but a string is a class in Java that stores a series of characters. Those characters are actually String-type objects. Since strings are objects we can ... Read More

Storage of String in Java

Shriansh Kumar

Shriansh Kumar

Updated on 05-May-2023 17:55:07

407 Views

A string is a class in Java that stores a series of characters. Those characters are actually String-type objects. The value of string is enclosed within double quotes. The string class is available in java.lang package. In this article, we will look into the storage mechanism of strings in ... Read More

Java Program for Decimal to Binary Conversion

Shriansh Kumar

Shriansh Kumar

Updated on 02-May-2023 18:58:58

5K+ Views

The number system is of four types: Binary, Octal, Decimal and Hexadecimal with base value 2, 8, 10 and 16 respectively. The base value depends on the number of digits contained by number system. For example, hexadecimal number system contains 16 digits i.e. 0 to 9 and A to F. ... Read More

Advertisements