[Solved] How to add 25 years(integer variable) to a date field in java [duplicate]

[ad_1]

It depends on the type that employee.getdate_of_birth() returns. If its a LocalDate, you can do employee.getdate_of_birth().plusYears(maxage). There are similar methods for days, months and seconds.

7

[ad_2]

solved How to add 25 years(integer variable) to a date field in java [duplicate]