OCA Qeydler

..:: Chapter 1 ::..

Deyishen adlari yalniz herfle, $ ve _ simvolla bashlaya biler. 

import classname ile edilirse, bu wildcard la importdan ustun sayilir. meselen

import a.Test;

import a.*;

1ci ustun sayilir.

lang package default olaraq import olunur

class bir basa directory daxilinde yerlesirse, classin bashinda package qeyd olumur. 

/my/directory/A.java - qeyd olunmur.

/my/directory/pack/A.java - package pack; qeyd olunacaq.

Calling System.gc() suggests that Java might wish to run the garbage collector.

Java is free to ignore the request

hemise fikir ver

long value1 = 12L; ve ya 12l

float value2 = 12.1f;

..:: Chapter 2 ::..

1. If two values have different data types, Java will automatically promote one of the values

to the larger of the two data types.

2. If one of the values is integral and the other is floating-point, Java will automatically

promote the integral value to the floating-point value’s data type.

3. Smaller data types, namely byte, short, and char, are first promoted to int any time

they’re used with a Java binary arithmetic operator, even if neither of the operands is

int.

4. After all promotion has occurred and the operands have the same data type, the resulting

value will have the same data type as its promoted operands.


Comments

Popular posts from this blog

Validation for AZ phone numbers with RegEx in Java

Java necə işləyir, kod nədir ?

@Transactional annotation haqqinda. Cascade istifade olunmasi