Complete the code to start building a User object using the builder pattern.
User user = User.[1]();The builder pattern usually starts with a static method named builder() to create a builder instance.
Complete the code to set the user's name in the builder.
User user = User.builder().[1]("Alice").build();
In builder patterns, the setter methods usually have the same name as the field, here name().
Fix the error in the builder usage to correctly set the user's age.
User user = User.builder().age[1]30).build();
Method calls require parentheses, so age(30) is correct.
Fill both blanks to build a User with email and then finish building.
User user = User.builder().[1]("user@example.com").[2]();
The builder method to set email is email(), and build() finishes the building process.
Fill all three blanks to build a User with name, age, and then finish building.
User user = User.builder().[1]("Bob").[2](25).[3]();
Use name() to set the name, age() to set the age, and build() to finish building.