# Initialization

Giving a variable its first value when it is created.

## What is **Initialization** in Java?

**Initialization** — Giving a variable its first value when it is created.

```java
class Game {
    void updateScore() {
        int score = 10;
        score = score + 5;
    }
}
```

Level: Novice · [More Java terms at this level](https://www.ask-codey.com/glossary/subjects/java/novice)

Updated: September 27, 2026

## In other subjects

- [Initialization in C#](https://www.ask-codey.com/glossary/initialization-c-sharp)

Source: https://www.ask-codey.com/glossary/initialization
