Ask Question

True or False and WHY:

Constructors can have names different from theirclasses.

+5
Answers (1)
  1. 15 October, 07:24
    0
    False

    Explanation:

    Constructors have to have the same name as their classes for proper syntax, if their names are different it will result in an error. Methods contained within the class can/should have different names, it is allowed because methods require return types while constructors cannot have return types.
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “True or False and WHY: Constructors can have names different from theirclasses. ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers