---
title: "Discussion on \"Understanding final in Java\" | Hashnode"
description: "Discussion on \"Understanding final in Java\". Compile-time initialization:\n\nFinal variables initialized at declaration:\n\npublic class Example {\n    final int COMPILE_TIME_CONSTANT = 10;\n}\n\nThis is resolved at compile-time and the value is embedded directly in the bytecode.\n\nStatic final variable..."
url: "https://hashnode.com/posts/understanding-final-in-java/66a540cab688477664ad63b1"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Understanding final in Java](https://harishkunchala.com/understanding-final-in-java?utm_source=hashnode&utm_medium=feed)

Compile-time initialization: Final variables initialized at declaration: public class Example { final int COMPILE\_TIME\_CONSTANT = 10; } This is resolved at compile-time and the value is embedded directly in the bytecode. Static final variable...

Jul 27, 2024 · 2 min read · harishkunchala.com  
Read the article

-   [#java](https://hashnode.com/tag/java)

## Written by

[Harish Kunchala](https://hashnode.com/@harish007)

@harish007

  
[View profile](https://hashnode.com/@harish007)

Flutter Developer, with a side of rust projects along the way.

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
