Computer Applications
Answer
| Implicit Conversion | Explicit Conversion |
|---|---|
| Implicit conversions are automatically performed by the Java compiler. | Explicit conversions are performed by the programmer using the cast operator. |
| Example: long a = 98453670116L; long result; int b = 100; result = a + b; | Example: int a = 10; double b = 25.5; float c = (float)(a + b); |
Related Questions
Rewrite the following program segment using logical operators:
if(x > 5) if(x > y) System.out.println(x + y);Identify the operator that gets the highest precedence while evaluating the given expression:
a + b % c * d - e
- +
- %
- -
- *
Write a Java program to obtain principal amount, rate of interest and time from user and compute simple interest.