19.8k views
3 votes
Identify the wrong pair of symbol-visibility scope

Select one:
a. #protected
b. -private
c. +public
d. !package

1 Answer

7 votes

Final answer:

The incorrect pair of symbol and visibility scope is !package. In UML, visibility scopes are represented by # for protected, - for private, and + for public. The tilde symbol, ~, is used for package visibility, not the exclamation mark. So option (d) is correct.

Step-by-step explanation:

The question is asking to identify which pair of symbol and visibility scope is incorrect. Visibility scope indicators are commonly used in Unified Modeling Language (UML) diagrams to define the access level of class members. In UML:

#protected: Indicating that the member is protected and accessible within its own class and by subclasses.

-private: Indicating that the member is private and only accessible within its own class.

+public: Indicating that the member is public and accessible from anywhere.

The incorrect pair is d. !package because there is no such symbol used to represent package visibility in UML. Instead, package scope is usually represented by ~ (tilde).

User Amrullah Zunzunia
by
7.4k points