Author: admin
-
Comments
Java Comments Java comments are text notes written in the code to provide an explanation about the source code. The comments can be used to explain the logic or for documentation purposes. The compiler does not compile the comments. In Java, comments are very similar to C and C++. In Java, there are three types of comments:…
-
Pointers
In most programming languages, a pointer variable stores the memory address of an object. However, in Fortran, a pointer is a data object that has more functionalities than just storing the memory address. It contains more information about a particular object, like type, rank, extents, and memory address. A pointer is associated with a target…
-
Basic Operators
Java provides a rich set of operators to manipulate variables. We can divide all the Java operators into the following groups − The Arithmetic Operators Arithmetic operators are used in mathematical expressions in the same way that they are used in algebra. The following table lists the arithmetic operators − Assume integer variable A holds…
-
Derived Data Types
Fortran allows you to define derived data types. A derived data type is also called a structure, and it can consist of data objects of different types. Derived data types are used to represent a record. E.g. you want to keep track of your books in a library, you might want to track the following…
-
Unicode System
Unicode is an international character set that encompasses a vast range of characters, symbols, and scripts from many languages across the globe. Unicode System in Java Java programming language, being platform-independent, has built-in support for Unicode characters, allowing developers to create applications that can work seamlessly with diverse languages and scripts. Before Unicode, there were…
-
Dynamic Arrays
A dynamic array is an array, the size of which is not known at compile time, but will be known at execution time. Dynamic arrays are declared with the attribute allocatable. For example, The rank of the array, i.e., the dimensions has to be mentioned however, to allocate memory to such an array, you use the allocate function. After the…
-
Type Casting
Java Type Casting (Type Conversion) Type casting is a technique that is used either by the compiler or a programmer to convert one data type to another. For example, converting int to double, double to int, short to int, etc. Type typing is also known as Type conversion. There are two types of cast typing allowed in Java…
-
Data Types
Data types define the type and value range of the data for the different types of variables, constants, method parameters, returns type, etc. The data type tells the compiler about the type of data to be stored and the required memory. To store and manipulate different types of data, all variables must have specified data types. Java data types are…
-
Arrays
Arrays can store a fixed-size sequential collection of elements of the same type. An array is used to store a collection of data, but it is often more useful to think of an array as a collection of variables of the same type. All arrays consist of contiguous memory locations. The lowest address corresponds to…
-
Variable Types
What is a Java Variable? A variable provides us with named storage that our programs can manipulate. Each variable in Java has a specific type, which determines the size and layout of the variable’s memory; the range of values that can be stored within that memory; and the set of operations that can be applied…