Các câu hỏi phỏng vấn và câu trả lời về phần "Core Java - OOPs concepts: Initial OOPs" - Phần 5: Từ khóa final
If you make any variable as final, you cannot change the value of final variable(It will be constant).
Final methods can't be overriden.
Final class can't be inherited.
A final variable, not initalized at the time of declaration, is known as blank final variable
Yes, only in constructor if it is non-static. If it is static blank final variable, it can be initialized only in the static block
Yes, such as, public static final void main(String[] args){}.
Nguyễn Thị Bảo Trang
» Tin mới nhất:
» Các tin khác: