- 
    Type:
Bug
 - 
    Resolution: Not an Issue
 - 
    Priority:
  P4                     
     - 
    None
 - 
    Affects Version/s: 23
 - 
    Component/s: core-libs
 
- 
        generic
 - 
        generic
 
                    A DESCRIPTION OF THE PROBLEM :
Example code written in scala
```
val formatter = DateTimeFormatter.ofPattern("YYY-MM-dd")
List.range(28, 32).foreach { day =>
assertEquals(
LocalDate.of(2024, 12, day).format(formatter),
s"2024-12-$day"
)
}
```
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
run the linked code, for the date 29.12.2024, 30.12.2024 and 31.12.2024
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
for the date 29.12.2024, 30.12.2024 and 31.12.2024 results I expect 2024-12-29, 2024-12-30, 2024-12-31
ACTUAL -
for the date 29.12.2024, 30.12.2024 and 31.12.2024 results are 2025-12-29, 2025-12-30, 2025-12-31
---------- BEGIN SOURCE ----------
val formatter = DateTimeFormatter.ofPattern("YYY-MM-dd")
List.range(28, 32).foreach { day =>
assertEquals(
LocalDate.of(2024, 12, day).format(formatter),
s"2024-12-$day"
)
}
---------- END SOURCE ----------
            
Example code written in scala
```
val formatter = DateTimeFormatter.ofPattern("YYY-MM-dd")
List.range(28, 32).foreach { day =>
assertEquals(
LocalDate.of(2024, 12, day).format(formatter),
s"2024-12-$day"
)
}
```
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
run the linked code, for the date 29.12.2024, 30.12.2024 and 31.12.2024
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
for the date 29.12.2024, 30.12.2024 and 31.12.2024 results I expect 2024-12-29, 2024-12-30, 2024-12-31
ACTUAL -
for the date 29.12.2024, 30.12.2024 and 31.12.2024 results are 2025-12-29, 2025-12-30, 2025-12-31
---------- BEGIN SOURCE ----------
val formatter = DateTimeFormatter.ofPattern("YYY-MM-dd")
List.range(28, 32).foreach { day =>
assertEquals(
LocalDate.of(2024, 12, day).format(formatter),
s"2024-12-$day"
)
}
---------- END SOURCE ----------