What are the 4 primitive data types?
What is a string?
It has properties of a primitive data type but it is a java class.
It is used to save strings of any length. The class String offers many existing methods for processing strings.
What is a variable?
It stores values in the application memory. They are similar to attributes, but the can only be used in the method body.
What are arithmetic operators?
they can execute mathematical functions
What are logical operators?
These are operators used to run logical functions, they return a value of true or false and can only result in a boolean.
What are relational operators?
They compare expressions against each other and return boolean as the result type.
What is a concatenation of strings (operator)?
It is a function of the data type String that creates a new string from two existing strings through simply stringing them together.
What are control structures?
They are elements of a programming language for conditional or nested execution of statements.
It enables controlled repeat execution of statements. The most important control structures in Java are:
Explain conditional branches in more detail.
Explain loops in more detail.
Loops allow sequential execution of the statements, the number of iterations of the loop is determined by the satisfaction of a loop condition.
What is a package?
It is an element used for structuring the java classes of a development project. Java classes are assigned to packages. Packages can themselves also contain packages.
The first line of the source text in a Java class always contains the package in which the class is located. The class names must be unique within a package.
Explain the visibility modifier.
**public** class Order {}
**public** voic calculateSum () {}class Order {}
voic calculate Sum() {}**protected** void calculateSum() {}
**protected** int quantityProduct;**private** void calculateSum() {}
**private** int quantityProduct;