the code from the first example above doesn't seem to be compilable
... String firstName = faker.name.firstName(); String lastName = faker.name.lastName(); String fullName = faker.name.fullName(); ...
name is a method, thus parentheses are required so it should be like
name
... String firstName = faker.name().firstName(); String lastName = faker.name().lastName(); String fullName = faker.name().fullName(); ...
or even better (here no need for parentheses)
... var name = faker.name(); String firstName = name.firstName(); String lastName = name.lastName(); String fullName = name.fullName(); ...
Thanks for pointing out. Somehow got deleted when editing. Corrected it!
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
the code from the first example above doesn't seem to be compilable
nameis a method, thus parentheses are requiredso it should be like
or even better (here no need for parentheses)
Thanks for pointing out. Somehow got deleted when editing. Corrected it!