+ All Categories
Home > Documents > 56310957-semc-UML

56310957-semc-UML

Date post: 24-Oct-2014
Category:
Upload: sumet-bagwe
View: 152 times
Download: 0 times
Share this document with a friend
Popular Tags:
42
1. Which of the following phases of Software Development Life Cycle (SDLC) includ es translation of the requirements specified in the SRS document into a logical structure? 1, Coding 2, Design 3, Feasibility Analysis 4, Maintenance 2 2. """At the time of identifying the requirements, the development team and th e customer hold discussions and negotiate on the requirements that need to be included in the current iteration of th e software."" Which of the following software development approaches is depicted by the preceding statement?" 1, Prototyping approach 2, Win-win approach 3, Waterfall approach 4, Incremental approach 2 3. A value lifeline is used to represent changes in the value of objects over a period of time. Which of the following diagrams depicts this value lifeline? 1,Class diagram 2, Robust notation timing diagram 3, Concise notation timing diagram 4, Object diagram 3 4 ________ are the sequence of actions that form a single unit of work for an actor. 1, Use cases 2, Classes 3, State Machines 4, Communications 1 5 Which of the following diagrams shows how a class reacts when an event o ccurs? 1, Class diagram 2, Object diagram 3, State Machine diagram 4, Activity diagram 3 6 Which of the following software development approaches applies a combina tion of the iterative approach as well as the linear approach for development of a software system? 1, Prototyping approach 2, Spiral approach 3, Incremental approach 4, Waterfall approach
Transcript
Page 1: 56310957-semc-UML

�1. Which of the following phases of Software Development Life Cycle (SDLC) includes translation of the requirements specified in the SRS document into a logical structure?

1, Coding

2, Design

3, Feasibility Analysis

4, Maintenance

2

2. """At the time of identifying the requirements, the development team and the customer hold discussions and negotiate on the requirements that need to be included in the current iteration of the software."" Which of the following software development approaches is depicted by the preceding statement?"1, Prototyping approach

2, Win-win approach

3, Waterfall approach

4, Incremental approach

23. A value lifeline is used to represent changes in the value of objects over a period of time. Which of the following diagrams depicts this value lifeline?1,Class diagram2, Robust notation timing diagram3, Concise notation timing diagram4, Object diagram 34 ________ are the sequence of actions that form a single unit of work for an actor.1, Use cases2, Classes3, State Machines4, Communications 1

5 Which of the following diagrams shows how a class reacts when an event occurs?1, Class diagram2, Object diagram3, State Machine diagram4, Activity diagram 36 Which of the following software development approaches applies a combination of the iterative approach as well as the linear approach for development of a software system?1, Prototyping approach

2, Spiral approach3, Incremental approach4, Waterfall approach

Page 2: 56310957-semc-UML

27 The incremental approach of software development includes three phases in each increment. Identify the phases from the following options.1, Risk Analysis, Design, Implementation2, Planning, Design, Implementation3, Customer communication, Design, Implementation4, Design, Implementation, Analysis

48 Which of the following views of a system represents the physical system including the files and components required to assemble the system?1, Process view2, Design view3, Implementation view4, Deployment view

39 "Peter is hired as a consultant to develop a payroll application for Maccus, Inc, a manufacturing organization. Peter analyses the existing system and as communicated by Maccus, Inc, identifies the following functional requirements of the application:* The software should perform basic calculations for pay. * The software should calculate deductions such as tax, loans, and national insurance. * The software should be able to handle various pension schemes.

Next, Peter has to depict these functional requirements diagrammatically. Which of the following UML diagrams should Peter use to depict the software requirements of the payroll system?"1, Use case diagrams2, Sequence diagrams3, Component Diagrams4, Composite structure diagrams

110 Smart Accessories Inc. has recently got an Inventory Management System developed for maintaining the stock at the central warehouse of the company. This software is developed by ITExperts Consultants. Among various other functions performed by the software, it identifies the stock at hand of a specific item and its reorder level. However, when the application is deployed and made functional at the site, the system gives incorrect output for the reorder level of the specified item. The management of Smart Accessories informed ITExperts Consultants about the error in the software and asked them to look into the matter. Which of the following phases of the RUP life cycle does the preceding problem fall?1, Inception2, Transition3, Elaboration

4, Construction

2

11 Sam is assigned the task of detecting errors in the code of a banking software. In which SDLC phase is Sam currently working?

1, Coding2, Design

Page 3: 56310957-semc-UML

3, Testing4, Maintenance

312 John is working on a project that is being developed by using the Waterfall approach. Currently, he is translating the identified requirements into a logical structure that later needs to be implemented in a programming language. Which phase of waterfall approach is John currently working on?1, Construction2, Analysis3, Design4, Initiation 313 John needs to create various artifacts of a system graphically, and represent a graphical relation between different components. Which building block(s) of UML will John use in this case?1, Basic UML constituents and Relationships2, Diagrams and Relationships3, Basic UML constituents and Diagrams4, Relationships only

214 How does OOAD use the OO approach to solve real world problems?1, OOAD uses OO approach to analyzethe system requirements and break a large and complex system into smaller and simpler components.2, OOAD uses OO approach to analyze the requirements and design of the software system only in terms of the objects, but not encapsulation and abstraction.3, OOAD uses OO approach to analyze the system requirements, and combine smaller components into a large and complex system.4, OOAD uses OO approach to analyze the requirements and design of the software system in terms of object attributes. 1

15 John is working on the development of a software project on inventory management. He is assigned the task of developing a module on the receipt of inventory parts from different suppliers. However, he first needs to draw an object diagram representing the relationship between suppliers and parts. From the figures given in the exhibit, identify the correct object diagram for John to accomplish this task. Click the Exhibit button to view the exhibit.

1, a2, b3, c4, d 1

16 Sam is working on the development of a software project related with the

Page 4: 56310957-semc-UML

management of online courses. He is assigned the task of developing a module for online registration of students for different courses. To begin this activity, he first needs to create an interaction diagram to represent online registration of a course. From the figures given in the exhibit, identify the correct diagram to accomplish this task. Click the Exhibit button to view the exhibit.

1, a

2, b

3, c

4, d 3

17 While implementing the iterative approach to create your software system, you need to establish the project scope for each iteration. What sequence of steps will you perform to achieve the same?"(1), 1. Identify the requirements.2. Assess the efforts required to implement the requirements.

3. Analyze the impact of implementing each requirement of the system.

4. Set priorities for the requirements to identify successive iterations."

"(2), 1. Identify the requirements.2. Set priorities for the requirements to identify successive iterations.3. Assess the efforts required to implement the requirements.4. Analyze the impact of implementing each requirement of the system." "

(3),1. Set priorities for the requirements to identify successive iterations.2. Identify the requirements.3. Analyze the impact of implementing each requirement of the system.4. Assess the efforts required to implement the requirements."

("4), 1. Assess the efforts required to implement the requirements.2. Identify the requirements.3. Set priorities for the requirements to identify successive iterations.4. Analyze the impact of implementing each requirement of the system." 2

18 "In an envisioned automobile service centre, the automobile engineer, after fixing a motor car, will be required to generate a report of the tasks performed by him on the car. While developing a model of the automobile centre by using the iterative approach, Generate Report is identified as one of the use cases in the iteration. Based on this report, a Bill of Charges will be printed for the customer to pay. As a result, Print Bill is identified

as another use case. This use case will be implemented in the next iteration.

Page 5: 56310957-semc-UML

How will you relate the Print Bill to the Generate Report in the second iteration?"

1, By using the Generalization relationship

2, By using the Association relationship

3, By using the Extends relationship

4, By using the Include relationship 3

19 The __________ enables you to focus on the functions performed by the software system in each iteration.

1, use case

2, system boundary

3, activity diagram

4, sequence diagram 2

20 Which of the following business modeling constructs shows how a particular function described in a use case is implemented?

1, Business actor

2, Collaboration

3, Business Worker

4, Business entity 2

21 When an additional behavior is added to an existing use case to obtain a new use case, then the use cases are said to share the ________ relationship amongst them.

1, generalization

2, include

3, extend

4, composite 3

22 Which of the following use cases describes the software system in three terms: information, input, and output?

Page 6: 56310957-semc-UML

1, Filled

2, Facade

3, Focused

4, Business 2

23 Which of the following is a technique that involves the task of designing a series of user interfaces on paper before developing a software system?

1, Storyboarding

2, Preparing questionnaires

3, Interviewing Stakeholders

4, Brainstorming 1

24 Which of the following business modeling constructs represents an external entity that interacts with the business process?

1, Business worker

2, Business actor

3, Business entity

4, Business use case 2

25 Which of the following contains the cost benefit justification for a project?

1, Business case

2, SRS document

3, Questionnaire

4, Interactive storyboard 1

26 ____________ enables you to focus on the functions performed by the software system in each iteration.

1, Test case

2, Active storyboard

3, Passive storyboard

Page 7: 56310957-semc-UML

4, System boundary 4

27 "Jonathan is working as a Service Engineer in an automobile service centre. He is required to repair and fix the motor cars that are brought to the service center. He may be required to replace the old parts of the motor cars with new spare parts. His responsibilities, therefore, include updating the inventory records with the current status regarding the availability of parts. Also, when the stock of spare parts reaches its reorder level, he is required to forward a requisition for the particular spare part to the parts supplier.

Identify the role of Jonathan in the preceding scenario to create the Business Process model."

1, Business actor only

2, Business actor and collaboration

3, Business actor and business worker

4, Business entity only 3

28 "In the QuickHeal Hospital, three departments, namely, Neurology, Cardiology, and Orthopedics have been set up for the treatment of patients with respective ailments. As a result, the doctors attached with each department are categorized as Neurologist, Cardiologist, and Orthopedician.

How will you relate the Neurologist, Cardiologist, and Orthopedician doctors with the Doctor behavior in your design for the hospital system?"

1, By using the Generalization relationship

2, By using the Extends relationship

3, By using the Association relationship

4, By using the Include relationship 1

29 "Thomas, a photographer, created the requirements for a website to display some of his digital photos. Among various requirements, one of the requirements that he identified was that the user should be able to easily upload photos, create galleries, and enter information about the photos. The details about the use case, Upload Photos are as follows:

Actor Step

Page 8: 56310957-semc-UML

Photographer Selects photo to be uploadedPhotographer Selects gallery that photo should be uploaded to or creates a new galleryPhotographer Provides photo details such as camera and artist's commentsPhotographer Changes or deletes the photos, if necessary

The test case identified for the Upload Photos use case checks whether or not the software system performs the following actions:Select the photoSelect the gallery or create a new galleryProvide the photo detailsChange or delete the photo

However, when Thomas performed backward traceability, he verified that the test cases are not adequate to test the use case, Upload Photos. Analyze the scenario, and identify the test cases that are required to test the given use case.""1, Select the photosSelect a galleryCreate a galleryEnter photo detailsChange the details of a photo Remove a photo and its details"

"2, Select the photosSelect a galleryEnter photo detailsChange the details of a photo Remove a photo and its details"

"3, Select the photosCreate a galleryEnter photo detailsChange the details of a photo Remove a photo and its details"

"4, Create a photoSelect the photosCreate a gallerySelect a galleryEnter photo detailsChange the details of a photo Remove a photo and its details" 1

30 "Consider the following scenario:A patient contacts the hospital reception for an appointment with a doctor. The receptionist checks the availability of the doctor and gives an appointment to the patient. This appointment is entered in the doctor�s schedule by the receptionist.

John is asked by his supervisor to realize the use case, Take appointment in the design phase. He identifies the following participating classes for this use case:AppointmentScheduleReceptionContact

Page 9: 56310957-semc-UML

Availability

Has John identified the participating classes correctly? If not, identify the correct participating classes for the given use case."1, Yes, the participating classes identified by John are correct."2, No, the participating classes identified by John are incorrect. The participating classes should be:AppointmentScheduleDoctorReceptionistContact""3, No, the participating classes identified by John are incorrect. The participating classes should be:AppointmentScheduleDoctorPatient""4, No, the participating classes identified by John are incorrect. The participating classes should be:AppointmentScheduleDoctorAvailabilityPatient" 331 "Consider the scenario for a hotel reservation system:The use cases required to implement the requirements of the first iteration are:* Make reservation* Check in guest* Check out guestThe make reservation use case allows either a guest or the receptionist to reserve a room in the hotel. The check in guest use case allows the receptionist at the hotel to validate the guest details and check the guest in. The check out guest use case allows the receptionist to complete the payment formalities before the guest leaves the hotel.Sam draws a figure to depict the use case diagram with the system boundary for the first iteration of the hotel system.Click the Exhibit button to view the figure. Which of the following options is correct with respect to the given figure?"

1, The figure drawn by Sam is correct.

2, The figure drawn by Sam is incorrect. The system boundary should include the actors, Guest and Receptionist along with the use cases.

3, The figure drawn by Sam is incorrect. The System boundary should contain the use case along with the actor, Receptionist. This is because Receptionist is member of the Hotel.

4, The figure drawn by Sam is incorrect. The make reservation use case is either initiated by the Guest or the Receptionist. Therefore, the line from both the actors to the make reservation use case is incorrect. 1

Page 10: 56310957-semc-UML

32 John is assigned the task of documenting the inputs provided by the stakeholders. While documenting the inputs, he missed to mention the probability of change in the various requirements in future. Which of the following attributes did John miss to mention in the document?

1, Status

2, Uncertainty

3, Rank

4, Stability 4

33 Joseph is assigned the task of managing the requirements of a software system to be developed. He is currently analyzing economic, technical, and operational feasibility of the software to be developed. In which phase of requirement management is Joseph currently working?

1, Requirements analysis and negotiation

2, Requirements gathering

3, Requirements specification

4, Requirements validation 2

34 Sam is assigned the task of developing a storyboard that consists of simulations and various animations. Which type of storyboard(s) can Sam use to accomplish this task?

1, Active and Passive

2, Active and Interactive

3, Interactive and Passive

4, Only Interactive 2

35 "John has developed a software on inventory management system that involves various entities such as suppliers, buyers, and data entry operator. The data entry operator updates all the transactions made by the buyer/supplier in the system. Identify the secondary actor(s) in this scenario."

1, Suppliers and data entry operator

2, Suppliers and Buyers

Page 11: 56310957-semc-UML

3, Buyers and data entry operator

4, Data entry operator only 2

36 John has developed various use case diagrams for a library management system. However, later he found that a use case, checkBookDetails, is missing. The functions of this use case are required in the functions of the existing use cases, issueBook and deleteBook. Therefore, John decided to modify the existing use case diagram by redefining the functions of the actors to represent the desired functionality. Identify whether John has taken the correct decision? If not, identify what should John have done to enhance the existing use case of the library management system.

1, He should have redefined the flow of events to represent the desired functionality.

2, He should have added the checkBookDetails use case in the existinguse case diagram and connected it with the issueBook and deleteBook use cases by using an include relationship.

3, He should have extended the issueBook and deleteBook use cases to incorporate the desired functionality.

4, He took the correct decision.

2

37 "You need to develop a Library Management System for a library. For this, you have created a BookTransaction class that includes an operation named CalculatePenalty. The operation needs to be invoked every time a book, borrowed earlier, is returned by a member. This operation is used to calculate the penalty, if applicable, to be paid by the member if the book is returned after the due date. No other class is able to access this operation except for the container class. The operation accepts two Date type parameters, namely, DateOfIssue and DateOfReturn and returns a float value to the invoking function.

Provide the correct syntax for the declaration of the above mentioned operation in a class diagram."

1, -CalculatePenalty(DateOfIssue:date,DateOfReturn:date):float

2, #CalculatePenalty:(date:DateOfIssue,date:DateOfReturn):float

3, -CalculatePenalty:float(DateOfIssue:date,DateOfReturn:date)

4, ~CalculatePenalty(DateOfIssue:date,DateOfReturn:date):float 1

Page 12: 56310957-semc-UML

38 "You need to develop a Library Management System for a library. For this, you have created a BookTransaction class that includes an attribute named Penalty. If a member returns borrowed books after the due date, the amount of penalty payable by that member for the delay in returning the books is stored in the attribute, Penalty. Penalty cannot be accessed outside the BookTransaction class and its data type is float. The default value of Penalty is 0.0 and only one value can be stored in it at any given time.

Provide the correct syntax for the declaration of the attribute Penalty in a class diagram."

1, -Penalty:Float=[0.0] :1

2, -Penalty:Float [1] = 0.0

3, ~Penalty:Float [1]:0.0

4, #Float:Penalty[1] = 0.0 2

39 "InfoVision Inc. is designing different modules for automation of the NewAge Bank. The module for the ATM system of the bank will involve accepting a card from the bank customer. The customer can be holding a credit or a debit card. Before the customer is allowed to request for a transaction, the card must be validated. The CardScanner accepts the card. The ValidateCard class checks the card and validates it. The structure of the sequence diagram has been developed. However, the message flow among the objects has not been defined.

Visualize the sequence diagram and provide the correct messages that need to be passed within the sequence diagram."

"1, The following operations should be depicted to complete the sequence diagram:

-- The object of the ValidateCard class invokes the CheckCreditCard() method of the ValidateCard class if the condition [CardType=CC] evaluates to True.-- The object of the ValidateClass invokes the CheckDebitCard() method of the ValidateCard class if the condition [CardType=DC] evaluates to True."

"2, The following operations should be depicted to complete the sequence diagram:-- The object of the CardScanner class invokes the CheckCreditCard() method of the ValidateCard class and on its failure to validate the card, invokes the CheckDebitCard() method of the same class."

"3, The following operations should be depicted to complete the sequence diagram:-- The object of the ValidateClass invokes the CheckCard() method of the Validat

Page 13: 56310957-semc-UML

eCard class."

"4, The following operations should be depicted to complete the sequence diagram:-- The object of the CardScanner invokes the CheckCreditCard() method of the ValidateCard class if the condition [CardType=CC] evaluates to True.-- The object of the CardScanner invokes the CheckDebitCard() method of the ValidateCard class if the condition [CardType=DC] evaluates to True."

4

40 "Jonathan is working as an automobile mechanic in an automobile service centre. Once he finishes repairing a motor car assigned to him, he records the tasks performed by him on the car. On the basis of the tasks performed, a bill of charges is generated that is payable by the customer. The record of tasks performed is stored in the object of the TaskPerformed class. The bill of charges is generated by the object of the Bill class.

Visualize the sequence diagram for the preceding scenario, and identify the messages and the components involved within the sequence diagram that will generate the bill of charges."

"1, The sequence diagram should depict invoking of the following message:-- TasksPerformed class invokes the GenerateBill() method of the Bill class."

"2, The sequence diagram should depict invoking of the following messages: -- Jonathan first invokes the EnterTasks() method of the TasksPerformed class.-- Jonathan then invokes the GenerateBill(TasksPerformed) method of the Bill class."

"3, The sequence diagram should depict invoking of the following message:-- Jonathan first invokes the GenerateBill(TasksPerformed) method of the Bill class.-- The Bill class then invokes the EnterTasks() method of the TasksPerformed class."

"4, The sequence diagram should depict invoking of the following message:-- Bill class self-invokes the GenerateBill(TasksPerformed) method contained by it."

2

41 "Bryan needs to model the functioning of a coaching institute, New Era Studies. The coaching institute provides educational services and identifies the students in three groups depending on their level of studies, namely, Elementary, Middle, and High School students. Bryan, while designing the model creates a class Students. He also creates separate classes, namely, Elementary, Middle, and High for each level of study group. In the class diagram for the institute, he has related these three classes with the Students class using a

Page 14: 56310957-semc-UML

Generalization relationship symbol.

Analyze if the relationship amongst these classes is correctly depicted. Also provide the correct relationship in case the existing relationship is incorrect."

1, The relationship depicted amongst these classes is correct.

2, The relationship depicted amongst these classes is incorrect. The classes should be related using Dependency relationship.

3, The relationship depicted amongst these classes is incorrect. The classes should be related using Realization relationship.

4, The relationship depicted amongst these classes is incorrect. The classes should be related using Aggregation relationship.

1

42 The customers of a telecommunication company lodge their complaints related to the various subscribed services on the company's website. The complaints are stored in an object of the CustComplaint class in the Customer Care system. These complaints are addressed by the customer care executives appointed by the company. While addressing the complaints, the executives need the complaint number and the complaint text. The system uses the object of the CustComplaint class to provide these details to the executives. The process of providing the complaint number and the complaint text to the executives by using the object of the CustComplaint class needs to be depicted in an activity diagram. Which of the following elements will you use in the activity diagram to depict the conversion of an object of the CustComplaint class into complaint number and complaint text?

1, Fork

2,Join

3, Transformation

4, Flow Final

3

43 "The City Departmental Store has announced heavy discounts on some of its products during the ongoing festive season. The store has also announced that the customers who are not satisfied with the product they purchased can return the same within 10 days of purchase. The store needs to kee

Page 15: 56310957-semc-UML

p a track of all the products so that they can be re-ordered whenever the need be. They also need to keep a track of the products that are defective so that they can be replaced. Robin, a designer, is required to develop the model for the functioning of the departmental store. While developing the State Machine diagram for the products in the store, Robin identified the following states of the products:

-- In Stock-- Out of Stock-- Returned

However, the design was rejected by the systems design specialist. Analyze the scenario and provide the most suitable states that Robin should incorporate in his design." "1, The correct states for the products should be identified as:

-- In Stock-- Out of Stock-- Being Sold-- Returned" "2, The correct states for the products should be identified as:

-- In Stock-- Out of Stock-- Being Sold-- Sold-- Returned-- Defected" "3, The correct states for the products should be identified as:

-- In Stock-- Out of Stock-- Being Sold-- Returned-- Defected" "4, The correct states for the products should be identified as:

-- In Stock-- Out of Stock-- Being Sold-- Not Discounted-- Defected" 2

44 Jonathan is developing an activity diagram for the Library Management System. Presently, he needs to depict the Book Return process in the diagram. When a member returns books, the delay in returning each book and the penalty applicable should be calculated. Once penalty is calculated for each book returned by a member, the total penalty should be calculated and the system should print a consolidated penalty slip to be issued to the concerned member. The activity diagram should depict the correct flow of these sub processes. Suggest which of the following elements of an activity diagram should Jonathan use to depict the sub processes for calculating delay and penalty for each book?

1, Pins and Transformation

2,Forks and Joins

Page 16: 56310957-semc-UML

3, Expansion Region

4, Flow Final

3

45 How many compartments does a class notation in UML have?

1, 2

2, 3

3, 4

4, 1

2

46 From the following options, identify the correct syntax for declaring an attribute in a class diagram.

1, visibility name type: multiplicity = default {property-string}

2, visibility name type = default multiplicity {property-string}

3, visibility name: type multiplicity = default {property-string}

4, visibility type name: multiplicity = default {property-string}

3

47 Which of the following elements of an activity diagram can be used to model parallel flow of activities?

1, Pins

2, Forks

3, Transformation

4, Flow final

2

48 In a program, a particular step is to be executed repeatedly, changing values of a variable, j from 1 to 5. How will you depict the execution of this step in a sequence diagram?

Page 17: 56310957-semc-UML

1, [ j :1 .. 5 ]

2, *[ j = 1 .. 5 ]

3, [ j := 1 .. 5 ]

4, *[ j := 1 .. 5 ]

4

49 "Sam is working on the development of software for an online book store. In this system, when the customer places an order for a book, the system checks for the availability of the book and displays the quantity available to the customer. The customer makes the payment, and the sales department dispatches the book. If the book is not available, the order processing is held until the stock arrives.

Sam has represented the preceding transactions by using an activity diagram. However, Sam's supervisor wants him to modify the activity diagram so that it clearly specifies which activity is performed by which class. Also, his supervisor wants him to depict that the order processing is put on hold till the stock arrives. Identify what Sam needs to do to fulfill the preceding requirements."

1, Sam should use swim lanes to depict the classes responsible for each activity. He should use pins to depict that the order processing is put on hold till the stock arrives.

2, Sam should use transformations to depict the classes responsible for each activity. He should use signals to depict that the order processing is put on hold till the stock arrives.

3, Sam should use transformations to depict the classes responsible for each activity. He should use expansion regions to depict that the order processing is put on hold till the stock arrives.

4, Sam should use swim lanes to depict the classes responsible for each activity. He should use signals to depict that the order processing is put on hold till the stock arrives.

4

50 "Angelina is a student of the OOAD UML course. She wants to write the steps for drawing an activity diagram for attending a lecture of OOAD UML at 8:00 AM in the University.

To attend the lecture, she has to get dressed to leave for the lecture. A decisi

Page 18: 56310957-semc-UML

on then has to be made, depending on the time available for the lecture to start, and the timings of the public trains. If there is sufficient time to catch the train, then she should take the train. Otherwise, she should take a bus to the University. Then, she has to attend the lecture, after which the Activity diagram terminates.The steps she writes to create the activity diagram are:

1. Identify the scope of the activity: Attending a lecture at 8:00am.2. Add the start and end states.3. Draw action states: Get dressed, take a train, attend lecture, and take a bus.4. Identify the first action state: Get dressed.5. Add a transition from the start state to the get dressed state.6. Add all the transitions of the action states: take a train, attend lecture, and take a bus.7. Add a transition from the take a bus state to end state.8. Add the decision point, on time to catch the train or not on time to catch the train 9. Identify concurrent actions, catch a train to University and catch a bus to university, and model those using forks and joins.Identify whether Angelina used the correct approach to create the activity diagram. If not, identify the correct steps that she should follow to create the required activity diagram."

1, Yes, Angelina has used the correct approach to create activity diagram

"2, No, Angelina should use the following steps to create the activity diagram:1. Identify the scope of the activity: Attending a lecture at 8:00am.2. Add the start and end states.3. Draw action states: Get dressed, take a train, take a bus, and attend lecture.4. Identify the first action state: Get dressed.5. Add a transition from the start state to the get dressed state.6. Add all the transitions of the action states: take a train, attend lecture, and take a bus.7. Add a transition from the attend lecture state to the end state.8. Add the decision point: on time to catch the train or not on time to catch the train 9. Identify concurrent actions, catch a train to University and catch a bus to university, and model those using forks and joins." "3, No, Angelina should use the following steps to create the activity diagram:1. Identify the scope of the activity: Attending a lecture at 8:00am.2. Add the start and end states.3. Draw action states: Get dressed, take a train, take a bus, and attend lecture.4. Identify the first action state: Get dressed.5. Add a transition from the start state to the get dressed state.6. Add all the transitions of the action states: take a train, attend lecture, and take a bus.7. Add a transition from the last action state to the attend lecture state.8. Add the decision point: on time to catch the train or attend lecture. 9. Identify concurrent actions, catch a train to University and catch a bus to university, and model those using forks and joins." "4, No, Angelina should use the following steps to create the activity diagram:1. Identify the scope of the activity: Attending a lecture at 8:00am.2. Add the start and end states.3. Draw action states: Get dressed, take a train, take a bus, and attend lecture

Page 19: 56310957-semc-UML

.4. Identify the first action state: Take a decision to catch the train or the bus.5. Add a transition from the start state to the first action state.6. Add all the transitions of the action states: get dressed, attend lecture.7. Add a transition from the attend lecture state to the end state.8. Add the decision point, on time to attend the lecture or not. 9. Identify concurrent actions, catch a train to University and catch a bus to university, and model those using forks and joins." 2

51 What is an abstract class?

1, An abstract class is a class that has multiple objects having the same attribute values.

2, An abstract is a class that provides a mechanism to use operations and classes to work with different data types.

3, An abstract class is a class that does not have any direct instances.

4, An abstract class is a class that has objects, which fulfill more than one role.

3

52 What is the difference between an abstract class and an interface?

1, An abstract class provides the specification of methods, but an interface does not provide the specification of methods.

2, An abstract class allows you to create instances directly, but an interface does not allow you to create instances directly.

3, Implementation of methods of an abstract class is provided by derived classes, but implementation of methods of an interface cannot be provided by derived classes.

4, An abstract class contains attributes and methods that can be public, private, or protected, but an interface consists of only methods.

4

53 Which of the following options is correct about static modeling and dynamic modeling?

1, Static modeling includes class and object diagrams, whereas dynamic modeling includes interaction, activity, and state diagrams. 2, Static modeling helps in expressing and modeling the behavior of a system over a period of time, whereas dynamic modeling hel

Page 20: 56310957-semc-UML

ps in depicting the relationships and dependencies between the constituents of a system. 3, Static modeling represents the behavior of static constituents of a software system, whereas dynamic modeling represents the static or structural constituents of a software system. 4, Static modeling is also known as behavior modeling, and dynamic modeling is also known as structural modeling.154 Which of the following is NOT a guideline for creating state diagrams?1, Identify the collaboration for a system, class, or use case. 2, Use the sequential and concurrent states to simplify the state diagrams. 3, Ensure that an object attains a state from which there is no possible transition to other states. 4, Identify the events that cause a transition in the state of an object. 355 "John identified the following responsibilities of a library management software system:1. Maintain book information such as book ID, author, and price.2. Maintain staff information such as staff ID, name, and address.

Identify various classes to be used for this software."

1, Book, Author, Price

2, Staff, Name, Address

3, Book, Staff

4, Author, Price, Staff, Name

3

56 Joseph needs to create an object diagram for the Book class to be used in the development of the software for library management system. From the figure given in the exhibit, identify the correct diagram that Joseph should use to accomplish his task. Click the Exhibit button to view the exhibit.

1, a

2, b

3, c

4, d

2

57 Sam needs to represent the relationship between two objects of the Employee class diagrammatically. Which relationship diagram should Sam use in this case?

1, Generalization

2, Recursive Aggregation

3, Dependency

4, Qualified association

Page 21: 56310957-semc-UML

2

58 Mary needs to graphically represent an interface of a calculator by using UML. From the figure given in the exhibit, identify the correct diagram to accomplish this task. Click the Exhibit button to view the exhibit.

1, a

2, b

3, c

4, d

1

59 "Sam is assigned the task of developing software for a book shop. He currently needs to create a module to facilitate the issue of orders received and update the details of books sold in a database. However, before implementing this functionality in the code, Sam needs to graphically represent the interaction among various objects, such as Order and book database, in the form of messages ordered in a sequence of time. He created a diagram as shown in the exhibit. Click the Exhibit button to view the exhibit.

Identify the error in the diagram, if any."

1, The arrow labeled as "Transaction complete" should be actually labeled as destroyed.

2, The arrow labeled as "IssueOrder (o_num,o_code)" should actually be labeled as create.

3, The duration of time for the object, Order, should be greater than the Customer object.

4, The diagram is correct.

4

60 Consider a scenario of an inventory management system. Whenever an inventory item is ordered, the inventory manager issues the requested items and simultaneously updates the database to keep a track of the total number of inventory items that are currently present. Recently, an enhanced version of a particular inventory item has been introduced in the market, which the inventory manager wants to keep in the store. However, the inventory store has a limited capacity. Therefore, un

Page 22: 56310957-semc-UML

til the old version of such inventory items are not sold out, the new enhanced version cannot be introduced in the store. You need to graphically represent this scenario by using a state machine diagram. Which feature of state machine will you use in this case to represent such a scenario?

1, Entry and exit actions

2, Internal transitions

3, Activities

4, Deferred events

4

61 "Consider the following statements in the context of Architectural modeling:

Statement 1: Component diagram depicts the constituents of a software system grouped together based on a specific criteria.Statement 2: Deployment diagram depicts the various processing devices on which the components of the software system executes.

Which of the following options is correct with respect to the preceding statements?"

1, Statement A is True and Statement B is False.

2, Statement B is True and Statement A is False.

3, Both statements, A and B, are True.

4, Both statements, A and B, are False.

2

62 "Consider the following statements in the context of Component diagrams:

Statement 1: Deployment components include the components that form the executable system.Statement 2: Execution components include the components that are created when a system is running.

Which of the following options is correct with respect to the preceding statements?"

1, Statement A is True and Statement B is False.

2, Statement B is True and Statement A is False.

3, Both statements, A and B, are True.

Page 23: 56310957-semc-UML

4, Both statements, A and B, are False.

3

63 Which of the following statements is NOT a feature of a framework?

1, Represents a collection of classes or a library that enables you to perform a particular function without developing the code from the scratch

2, Provides the guidelines for handling system events

3, Defines abstract methods that receive messages in the derived class from the predefined classes

4, Contains abstract and concrete classes that realize interfaces to conform to predefined specifications

2

64 You are creating a file editing application that will be run in the DOS mode. You want the application to be Menu driven, and the menus should respond to mouse clicks. Which of the following Patterns will you make use of to simplify the implementation of the mouse functionality in your application?

1, Proxy pattern

2, Composite pattern

3, Facade pattern

4, Decorator pattern

3

65 Which of the following patterns can be used when you need to represent an object that is time consuming to create, with a simpler object?

1, Proxy

2, Composite

3, Façade

4, Decorator

1

66 Which of the following options is useful in making the design of a system reusable, solving

Page 24: 56310957-semc-UML

a problem in the most efficient way, and assigning responsibilities to classes?

1, Pattern

2, Framework

3, Interface

4, Package

1

67 The access dependency relationship is depicted by using a ___________ connecting the client package to the supplier package.

1, dashed arrow

2, solid arrow

3, half-headed arrow

4, bi-directional line

1

68 Which of the following diagrams can be used to organize various constituents of a software system

in logical group

1, Deployment diagram

2, Package diagram

3, Object diagram

4, Composite Structure diagram

2

69 "Consider the following scenario:

Sam has to write code in Java for an application that asks for entering the name and sex of a person. If the sex is Male, the application displays a welcome message saying Hello Mr. <Name> and if the sex is Female, the application displays a welcome message saying Hello Ms <Name>. For this, he creates a class named Person having methods for name and gender. Then, he creates two sub-classes, Male and Female that will print the welcome message on the screen.

Analyze the preceding problem and the partial solution, and identify what Sam ha

Page 25: 56310957-semc-UML

s to do next to accomplish the required task."1, Sam has to create a factory class that will return the welcome message depending on the data provided at runtime and print the names.

2, Sam has to create a builder class that will return the welcome message depending on the data provided at runtime and print the names.

3, Sam has to create a singleton class that will return the welcome message depending on data provided at runtime and print the names.

4, Sam has to create a proxy class that will return the welcome message depending on the data provided at runtime and print the names.

1

70 "Consider the following scenario:Jim�s team is given the responsibility of creating the design for an Inventory Management System. Jim's supervisor has asked him to design the AddStockDetails form. Also, he wants Jim to design three buttons in the form, namely, Add, Previous, and Close. The design of the buttons should be such that the Add button has a hovering effect, the Previous button displays text along with the button, and the close button has a hovering effect as well as displays text along with the button.

To accomplish the preceding task, Jim uses the composite pattern. Then, he creates a container class in the AddStockDetails form that will give the required effects to the button. Will Jim be able to accomplish the required task by creating a container class? If no, then identify the structural pattern that will help Jim accomplish the required task, and how?"

1, Yes, Jim is using the correct structural pattern. He will be able to accomplish the required task by usingthe container class.

2, No, Jim should use the Proxy pattern. Jim can create a proxy object to implement the required effects on the buttons.

"3, No, Jim should use the Decorator pattern. He should create a Decorator class that decorates theButtons, Add, Previous, and Close. Then, he has to derive two specific decorators, hoverDecorator and textDecorator from the main Decorator class, each of which performs the required type of decoration."

"4, No, Jim should use the Facade pattern. He should create a Facade class that creates a façade for theButtons, Add, Previous, and Close. Then, he has to derive two specific effects, hover and text from

Page 26: 56310957-semc-UML

the main Facade class, each of which performs the required task."

3

71 "Sam is working on the design of the library management system. He has created a class, Book that has the following attributes and operations:

bookCode: Stringbooktitle: StringQuantity: IntissueBook()returnBook()

The operation, issueBook() handles the task of issuing library book(s) to its members. The operation, returnBook() handles the task of accepting the book(s) returned by its users.

However, during the dynamic modeling phase, Sam realized that he would require another attribute, named checkAvailability() in the Book class to check the availability of the requested books in the library before the book can be issued.

Analyze the preceding scenario and identify the technique that is applied to alter the design."

1, Refactoring design is applied.

2, Session Façade is applied.

3,Factoring design is applied.

4, Unit testing is applied.

1

72 What is the purpose of the Expert pattern?

1, The expert pattern provides guidelines to assign responsibility to a class that contains the relevant information.

2, The expert pattern provides the guidelines for assigning responsibility to a new object of a particular class.

3, The expert pattern provides the guidelines for handling system events.

4, The expert pattern establishes common terminology for problems and their solutions to improve understanding.

1

73 What is Module viewtype?

Page 27: 56310957-semc-UML

1, Module viewtype specifies a collection of components where each of the components is an execution unit.

2, Module viewtype indicates a set of relationships among the components or modules of a software system with the development environment.

3, Module viewtype specifies the modules that implement a specific function.

4, Module viewtype depicts the resources allocated for the development of modules or components of the software system.

3

74 Which of the following is NOT a characteristic of a framework? 1, A framework represents a single class that enables you to perform a particular function without developing the code from scratch.

2, A framework contains abstract and concrete classes that realize interfaces to conform to predefined specifications.

3, A framework contains classes that can be extended by subclassing.

4, A framework defines abstract methods that receive messages in the derived class from the predefined classes.

1

75 Which of the following is NOT true about the inside view of the modeling design patterns?

1, It represents the structure of the design pattern as seen by the creator of the pattern.

2, It is depicted as a collaboration without parameters.

3, It represents the structure of the design pattern as a parameterized collaboration.

4, In this view, the collaboration has a structural and behavioral aspect.

3

76 John is working on the development of a software project on inventory management. He is required to create a package diagram to depict the relationship between various inventory parts such as automobile parts, computer parts, and furniture parts. From the figure given in the exhibit, identify the correct diagram to accomplish this task. Click the Exhibit button to view the exhibit.

1, a

Page 28: 56310957-semc-UML

2, b

3, c

4, d

4

77 "Sam is a part of the software development team for a book store. He is required to create a component, updateBookDetails, which updates the book details in the database. However, before he begins coding for this component, he needs to graphically represent the relationship between the updateBookDetails component and the classes, Book and Operator, by using a component diagram. From the figure given in the exhibit, identify the correct diagram to accomplish this task.

Click the Exhibit button to view the exhibit."

1, a

2, b

3, c

4, d

2

78 "Sam has developed a design model for a library management system by using various classes and methods. He now needs to generate code by using this design model. To begin with, he needs to generate code for the class diagram shown in the exhibit.Based on this class diagram, identify the code generated for the BookList class. Click the Exhibit button to view the exhibit." "1, public class BookList {private int Quantity;}}" "2, public class BookList {public void addBook (Book b) {}}" "3, public class BookList {private int Quantity;public void addBook (Book b) {}}" "4, public class BookList {private int Quantity;public void addBook() {}}" 379 Sam is assigned the task of developing software for an online book store. Before beginning with coding, he identified two major software components of the system, books database application and client program. Sam now wants to graphically represent the processing devices as well as the database server and client PC on which the books database and client program will execute, respectively.

Page 29: 56310957-semc-UML

To accomplish this task, he used deployment diagrams to represent these components graphically. Identify whether Sam used the correct diagram in this case. If not, identify the correct diagram. 1, He should have used the package diagram. 2, He has used the correct diagram. 3, He should have used the state diagram. 4, He should have used the component diagram. 280 "EasyHomeShopping Inc., is a well known online shopping site. Large number of customers have registered on this website to shop online for different types of products. The client application on Web performs the following functions:1. Checks the login details of the customer.2. Validates the account balance of the customer.3. Transfers the required amount from customer's account to the account of EasyHomeShopping Inc.

The preceding scenario results in accessing multiple server-side objects for a particular client. As a result, due to separate invocation of each server-side object by a client, network traffic has significantly increased resulting in performance degradation.

Which pattern should be used in this scenario so that the client does not access these server-side objects directly?" 1, Proxy 2, Decorator 3, Composite 4, Session Façade 481 "Jane has to design an online shopping website for Smart accessories, Inc. According to the initial requirements provided by Smart accessories, the website should provide the following features:* Should allow the users to browse through the catalog containing the items for sales* Should allow the users to buy products online

Jane decided to use the spiral approach for developing the Online Shopping website. Also, she identified the following dimensions of the Design process component:

Roles: System Designer Activity: Analysis of SRS Create UML diagrams Create design document

Deliverables: Design document

Has Jane chosen the correct life cycle model? Also, are the dimensions of the design process component identified by Jane correct? If not, identify the appropriate model and the dimensions of the design process component for developing the website?" 1, Yes, Jane has chosen the correct life cycle model. Also, the dimensions of the design process component identified by Jane are correct."2, No, Jane has not chosen the correct life cycle model and dimensions of the design process component. She should use the prototype approach as it can effectively trap the requirements of a wide range of users. Also, the dimensions of the design process component should be:

Roles: Project Manager System Analyst System Designer Software Engineer

Activity: Analyze requirements and create prototype Implement feedback on the evaluated prototype Deliverables: Prototype of the various Web pages of the shopping site" "3, Yes, Jane has chosen the correct life cycle model. However, the dimensions of the d

Page 30: 56310957-semc-UML

esign process component should be:

Roles: System Analyst System Designer

Activity: Analysis of SRS Create design document Deliverables: Design document" "4, No, Jane should use the waterfall approach for developing the Online Shopping website. Also, the dimensions of the design process component should be:

Roles: System Designer Software Engineer

Activity: Analysis of SRS Create UML diagrams Validate UML diagrams Create design document

Deliverables: Design document" 282 Which of the following is NOT true about quality process? 1, Quality of a software process includes the quality of the hardware used for software development. 2, Quality of a software process includes quality of the software models that are used for the software development process. 3, Quality of a software process includes quality of the quality process itself. 4, Quality of a software process includes quality of the software development process that is used to develop the software system. 1

83 "Refer to the figure given in exhibit. Which quality process element does the notation in the exhibit signify?Click the Exhibit button to view the exhibit." 1, Process-component 2, Start of process-component 3, End of process-component 4, Activity 3

84 What does distributed data processing describe in the context of the guidelines for determining the degree of influence of GSCs? 1, It describes the degree to which computer resource restrictions influence the development of the application. 2, It describes the degree to which the response time and throughput performance of a software application is influenced at the time of development. 3, It describes the degree to which the application communicates directly with the processor. 4, It describes the degree to which the application transfers data among components of the application. 4

85 While measuring the complexity of UML artifacts, you only need to measure the complexity of some static components. Identify which component does not fall under this category. 1, Use case diagram 2, Activity diagram 3, Class diagram 4, Component diagram 2

86 John is a part of a software development team that focuses on the quality of the code being generated using UML models. Identify the quality aspect that John needs to focus on. 1, Quality of visualization 2, Quality of specification 3, Quality of construction 4, Quality of documentation3

Page 31: 56310957-semc-UML

87 John wants to represent model elements for which UML does not have a specific notation. Which of the following options can he use to achieve this?1, Extend the vocabulary of UML by using stereotypes 2, Extend the vocabulary of UML by using constraints 3, Extend the vocabulary of UML by using tagged values 4, Tailor UML by using constraints and tagged values 1

88 Sam needs to identify the total number of FPs for the software of a library management system. To do so, he has identified the total number of files and interfaces. What else does he need to identify to accomplish his task? 1, Total number of inputs, outputs, and enquiries 2, Total number of inputs and outputs 3, Total number of inputs and enquiries 4, Total number of enquiries1

89 The planned productivity for a project was 2800 process components per month. However, the actual productivity is 1400 process components per month. Calculate the adjustment factor for this project. 1, 2 2, 4200 3, 0.5 4, 14003

90 "The management of the MyBookShop Inc., bookstore has decided to upgrade its website. As a result, new software containing the upgraded functionality needs to be created that will replace the existing software, and all the old data will be replaced with the new data. Sam is a part of the development team that is responsible for calculating the size of this project. He is assigned the task of calculating the Adjusted Point Function based on the following data:

Sum of Data FPs = 41Sum of Transaction FPs = 36FP Count for Conversion Functionality = 16Value Adjustment Factor = 1.23

Based on the preceding data, calculate the Adjustment Point Function." 1, 114.39 2, 1.42 3, 77 4, 94.71 191 Sam is a part of the software development team for an online banking system. He is currently working on a module that frequently accesses the database server for various transactions. An efficient functioning of this module depends upon specific processor requirements so as to ensure uninterrupted database transactions. Therefore, Sam assigned a value, 3, as the degree of influence for such resource restriction. Identify the GSC for this scenario. 1, Transaction Rate 2, Heavily Used Configuration 3, Performance 4, Online Data Entry292 "Sam is a part of the software development team creating software for a bank. However, before beginning with coding, he is asked to create various use cases of the system and calculate the complexity of those use case diagrams. While creating use cases, he identified actors as Customer and Staff, and identified use cases as Create Account, Delete Account, and Deposit Money. In addition, he identified the association relationship between the following:* Create account use case and Staff actor* Delete Account use case and Staff actor* Deposit Money use case and Customer actor How do you describe the complexity of the use case diagram in this case."1, Total number of actors = 2 2, Total number of use cases =3 3, Total number of relationships = 3 "4, Total number of actors = 2

Page 32: 56310957-semc-UML

Total number of use cases =3Total number of relationships = 3" 4

93 Sam is a part of the software development team for library management system. He is currently assigned the task of developing the functionality for two classes, UpdateBookDetails and UpdateMemberDetails. Both these classes are the implementation classes of the type class, Transaction. However, before implementing the functionality for these classes, Sam decided to first create class diagrams for these classes. In this diagram, he also wants to represent the difference between the type class and the implementation classes. View the exhibit and identify if the class diagram that Sam has drawn is correct. If it is incorrect, point out the errors. Click the Exhibit button to view the exhibit. 1, The class diagram is correct. 2, The class diagram is incorrect. The label <<Type>> needs to be replaced with {Type} and the label <<Implementation>> needs to be replaced with {Implementation} 3, The class diagram is incorrect. The label <<Type>> needs to be replaced with <<T>> and the label <<Implementation>> needs to be replaced with <<I>> 4, The class diagram is incorrect. The label <<Type>> needs to be replaced with {T} and the label <<Implementation>> needs to be replaced with {I} 1

94 John is a part of the software development team for an inventory management system. He is given various class diagrams for the software being developed. He is asked to measure the complexity of these diagrams in terms of the complexity of their operations by using the WMC metric. To begin this activity, he first selects the Inventory Manager class. He found that three operations of this class have complexities, 2, 8, and 14. Based on this data, he calculated the complexity of this class as 4. Identify whether this value is correct. If not, identify the correct value for the complexity. 1, The complexity value determined by John is correct. 2, The complexity value determined by John is incorrect. The correct value is 20. 3, The complexity value determined by John is incorrect. The correct value is 24. 4, The complexity value determined by John is incorrect. The correct value is 224. 3

95 "John needs to develop a design for a washing machine that consumes less power as compared to the other available machines in the market. To begin with, he first identified two main states, Operating state and Paused state, for the machine. Next, he identified that in the Operating state, the machine can be in any of the three sub-states: Washing, Rinsing, and Spinning. Now, he wants to capture a functionality in his design that if the machine's door is opened while it is in the Operating state, the machine goes into the paused state. However, the machine resumes back the substate in which it was operating as soon as the door is closed.

To model this functionality, he created a state diagram as shown in the exhibit.

Click the Exhibit button to view the exhibit.

From the exhibit, identify whether John has created the correct diagram to model the required functionality. If not, identify the error in the diagram."1, The circle containing H* should be removed altogether. 2, H* should be replaced with letter H. 3, The Paused state should be shown within the Operating state. 4, The diagram is correct. 2

Page 33: 56310957-semc-UML

96 "The management of MyBookShop Inc., bookstore has decided to upgrade their website. As a result, a new software containing the upgraded functionality needs to be created that will replace the existing software, and all the old data will be replaced with new data. Sam is a part of the development team that is responsible for calculating the size of this project. He is assigned the task of calculating the Adjusted Function Points based on the following data:

Sum of Data FPs = 40Sum of Transaction FPs = 35FP Count for Conversion Functionality = 15Total Degree of Influence = 57

Based on the preceding data, John calculated the Adjustment Point Function as 91.5. Check whether this value is correct. If not, identify the correct value."1, 109.8 2, 1.4 3, 75 4, The value is correct. 19700% Sam is assigned the responsibility to ensure that software products are developed as per the defined and documented sequence of activities and tasks. Which quality check is Sam working on? 1, Architecture quality 2, Process quality 3, Quality environment 4, Management quality 298 As a project manager, John wants to store some information in his UML diagrams for his reference. Which of the following options can he use for the same? 1, Stereotypes 2, Constraints 3, Stereotypes and constraints 4, Tagged values 4

99 To measure a software development process, Sam is asked to measure the technology dimension. What is the responsibility of Sam in this case? 1, Measure the activities and tasks related to a process component 2, Measure the output of a process component 3, Measure the role of a process component4, Measure the input of a process component 2

100 Which of the following options is true about Function Point (FP) estimation technique?1, It measures the number of resources required to complete a project. 2, It measures the duration of a project.3, It can be used to determine the effort required to develop a project.4, It estimates the productivity of a project. 3

101 Which of the following options is the process of converting of a value type to a reference type? 2, Casting 3, Unboxing 4, Boxing 4

102 Which of the following interfaces allows you to add item to and remove items from a specific location within the collection?1, IList2, IComaprable 3, ICollection4, IDictionary 1

103 Which of the following attributes for the custom XML format specifies th

Page 34: 56310957-semc-UML

at XmlSerializer serializes the class member as an XML attribute? 1, XmlElementAttribute 2, XmlArrayItemAttribute 3, XmlAnyElementAttribute4, XmlAttributeAttribute 4

104 Which of the following options allow you to create an instance of a delegate by specifying a block of inline code to be invoked by the delegate?1, Covariance2, Publisher3, Anonymous4, Subscriber 3

105 You have created an assembly, CalculateInterest.dll. You want that the assembly should be sharable and accessible to all the applications. Which of the following options will allow you to enable all applications to share and access the assembly?1, Multifile assemblies2, Single file assemblies3, Strong name 4, Global Assembly Cache 4

106 You want to modify the content of a file, Employee.txt. For this, you want that the pointer should be placed at the beginning of the file. Which of the following methods will allow you to accomplish the preceding task?1, Seek2, Write3, Read4, Flush 1

107 Paul has implemented the code in the application to log the events that occur in the application while it is accessed by a user. Now, you want to read the information from the event log. Which of the following properties of the EventLog class will you to get the information?1, Entries2, Log3, MachineName 4, Events 1

108 You are creating a method that returns a database object. Now, you want to convert the database object into an XML format. Which of the following methods of the XmlSerializer class allows you to accomplish the preceding task?1, FromTypes2, Deserialize3, CreateWriter4, Serialize 4

109 Brown is creating an application that adds a bonus to the salary of the employees of different departments. He has declared three variables that contains fixed bonus values for each department. This bonus value will be added to the employee's salary depending upon the salary and the department entered by the employee. Which of the following user-defined value types will you use to declare and use such variables?1, Constant2, Structure3, Class4, Enumeration 1

110 You have created a COM component that calculates and displays the annual salary of an employee. You want that the COM component should run on multiple platforms. Which of the following features of COM components will allow you to accomplish the preceding task?1, Portability2, IL Disassembler

Page 35: 56310957-semc-UML

3, Self-dependency4, Versioning 1

111 You are creating an application using Visual Studio. You want that an error message should be generated with all the detail information about the error if an any exception occurs while the application is executed. Which of the following methods of the Trace class will you to get the information?1, Assert2, Fail 3, WriteIf4, Write 2

112 You are creating an application using Visual Studio. In the application, you are creating a method that access the data from the database. You want that method should be invoked asynchronously. Which of the following options will you use to invoke the method asynchronously?1, EventArgs2, Event handler3, Delegates4, Events 3

113 You want to create an application that adds dynamically the employee details, employee ID and name. In addition, it displays the employee name on the basis of the value by key, employee ID. Which of the following code snippets will you use to accomplish the preceding task?"1, static void Main(string[] args) { Hashtable emp = new Hashtable(); emp.Add(""E001"", ""Smith""); emp.Add(""E002"", ""Jone""); emp.Add(""E003"", ""Scott""); Console.Write(""E001 employee is : {0}"", emp[""E001""]); Console.ReadKey(); }""2, static void Main(string[] args) { Hash table emp = new Hash table(); emp.Add(""E001"", ""Smith""); emp.Add(""E002"", ""Jone""); emp.Add(""E003"", ""Scott""); Console.Write(""E001 employee is : {0}"", emp); Console.ReadKey(); }""3, static void Main(string[] args) { Hashtable emp = new Hashtable(); emp.Add(E001, ""Smith""); emp.Add(E002, ""Jone""); emp.Add(E003, ""Scott""); Console.Write(""E001 employee is : {0}"", emp[""E001""]); Console.ReadKey(); }""4, static void Main(string[] args) { Hash table emp = new Hash table(); emp.Add(""E001"", ""Smith""); emp.Add(""E002"", ""Jone""); emp.Add(""E003"", ""Scott""); Console.Write(""E001 employee is : {0}"", emp[""E001""]); Console.ReadKey(); }" 1

Page 36: 56310957-semc-UML

114 You want to create a custom configuration validation class, myTextValidator that validates the length of a string should not exceed 50 characters and raises an exception if the length of the string is more than 50 characters. Which of the following code snippets will you use to accomplish the preceding task?"1, public class myTextValidator { public override void Validate(object value) { string text; text=(string)value; if(text.Length>50) { throw new NotImplementedException(); } } public override bool CanValidate(Type type) { if(type==typeof(string)) { return true; } else { return false; } }""2, public class myTextValidator:ConfigurationValidatorBase { public override void Validate(object value) { string text; text=(string)value; if(text.Length>50) { throw new NotImplementedException(); } } public override bool CanValidate(Type type) { if(type==typeof(string)) { return true; } else { return false; } }""3, public class myTextValidator:ConfigurationValidatorBase { public override void Validate() { string text; text=(string)value; if(text.Length>50) { throw new NotImplementedException(); }

Page 37: 56310957-semc-UML

} public override bool CanValidate(Type type) { if(type==typeof(string)) { return true; } else { return false; } }""4, public class myTextValidator:ConfigurationValidatorBase { public override void Validate(object value) { string text; text=(string)value; if(text.Length>50) { throw new NotImplementedException(); } } public override bool CanValidate() { if(type==typeof(string)) { return true; } else { return false; } }" 2115 You want to create a console application that stores text in a file, Myfile.txt and displays a message, "Content Written". Which of the following code snippets will you use to accomplish the preceding task?"1, string text = ""This is a sample file that .......""; FileInfo fileStore = new FileInfo(""Myfile.txt""); File fs = fileStore.Create(); byte[] encodetext = new UTF8Encoding(true).GetBytes(text); fs.Write(encodetext, 0, encodetext.Length); fs.Close(); Console.Write(""Content Written""); Console.ReadKey();""2, string text = ""This is a sample file that .......""; File fileStore = new File(""Myfile.txt""); FileStream fs = fileStore.Create(); byte[] encodetext = new UTF8Encoding(true).GetBytes(text); fs.Write(encodetext, 0, encodetext.Length); fs.Close(); Console.Write(""Content Written""); Console.ReadKey();""3, string text = ""This is a sample file that .......""; FileInfo fileStore = new FileInfo(""Myfile.txt""); FileStream fs = fileStore.Create(); byte[] encodetext = new UTF8Encoding(true).GetBytes(text); fs.Write(encodetext, 0, encodetext.Length);

Page 38: 56310957-semc-UML

fs.Close(); Console.Write(""Content Written""); Console.ReadKey();""4, string text = ""This is a sample file that .......""; FileInfo fileStore = new FileInfo(""Myfile.txt""); FileStream fs = fileStore.Create(); byte[] encodetext = new UTF8Encoding(true); fs.Write(encodetext, 0, encodetext.Length); fs.Close(); Console.Write(""Content Written""); Console.ReadKey();" 3116 You want to view the trace information of an application. The trace information should contain only the error and warning messages. Which of the following code snippets will you use to accomplish the preceding task?"1, <?xml version=""1.0""?><configuration> <system.diagnostics> <switches> <add name=""MySwitch"" value=""2""/> </switches> </system.diagnostics></configuration>"

"2, <?xml version=""1.0""?><configuration> <system.diagnostics> <switches> <add name=""MySwitch"" value=""0""/> </switches> </system.diagnostics></configuration>"

"3, <?xml version=""1.0""?><configuration> <system.diagnostics/> <switches> <add name=""MySwitch"" value=""3""/> <add name=""SourceSwitch"" value=""Warning""/> </switches></configuration>"

"4, <?xml version=""1.0""?><configuration> <system.diagnostics> <switches> <add name=""MySwitch"" value=""4""> <add name=""SourceSwitch"" value=""Warning""> </switches> </system.diagnostics></configuration>" 1

117 "You wanted to create an application that converts an integer-type value into an object-type value and displays the integer-type value and the object-type value to demonstrate boxing. For this, you wrote the following code snippet:

static void Main(String[] args) { num1 = 100; object obj = num1; num1 = 200;

Page 39: 56310957-semc-UML

Console.WriteLine(""The value-type value of num1 = {0} "", num1); Console.WriteLine(""The object-type value of obj = {0} "", obj); Console.ReadKey(); }

However, while executing the application, an error was generated. Analyze the code and provide the solution.""1, static void Main(string[] ) { int num1 = 100; object obj = num1; num1 = 200; Console.WriteLine(""The value-type value of num1 = {0} "", num1); Console.WriteLine(""The object-type value of obj = {0} "", obj); Console.ReadKey(); }""2, static void Main(string[] args) { int num1 = 100; object obj = num1; num1 = 200; Console.WriteLine(""The value-type value of num1 = {0} "", num1); Console.WriteLine(""The object-type value of obj = {0} "", obj); Console.ReadKey(); }""3, static void Main(string args) { int num1 = 100; object obj = num1; num1 = 200; Console.WriteLine(""The value-type value of num1 = {0} "", num1); Console.WriteLine(""The object-type value of obj = {0} "", obj); Console.ReadKey(); }""4, static void Main(string[] arguments) { int num1 = 100; object obj = num1; num1 = 200; Console.WriteLine(""The value-type value of num1 = {0} "", num1); Console.WriteLine(""The object-type value of obj = {0} "", obj); Console.ReadKey(); }" 2118 "You wanted to create an assembly, CurrencyConverter that converts the currency entered by a user into US dollars. For this, you wrote the following sequence of steps:

1. Create source code file, CurrencyConverter.2. Type the following command at the command prompt:csc CurrencyConverter.cs3. Save the source code file.4. Type CurrencyConverter.exe at the command prompt to execute the file.

However, after performing the preceding sequence of steps, you did not get the desired output. Analyze the preceding sequence of steps and provide the solution." "1, 1. Create source code file, CurrencyConverter.2. Type the following command at the command prompt:csc CurrencyConverter.cs3. Type CurrencyConverter.exe at the command prompt to execute the file.4. Save the source code file."

Page 40: 56310957-semc-UML

"2, 1. Create source code file, CurrencyConverter.2. Save the source code file.3. Type the following command at the command prompt:cs CurrencyConverter.cs4. Type CurrencyConverter.exe at the command prompt to execute the file."

"3, 1. Create source code file, CurrencyConverter.2. Save the source code file.3. Type the following command at the command prompt:csc CurrencyConverter.exe4. Type CurrencyConverter.cs at the command prompt to execute the file."

"4, 1. Create source code file, CurrencyConverter.2. Save the source code file.3. Type the following command at the command prompt:csc CurrencyConverter.cs4. Type CurrencyConverter.exe at the command prompt to execute the file."4

119 "You wanted to create an application that determines whether the file, Myfile.txt exists or not at the D: drive of a machine. If the file does not exist, it should be created at the D: drive of a machine and a message should be displayed, ""File Created"", else a message should be displayed, ""File already exists."" For this, you wrote the following code snippet:

string fileName = ""Myfile.txt""; if (!File.Exists(@""D:\"" + fileName)) { File fi = new File(@""D:\"" + fileName); FileStream fs = fi.Create(); fs.Close(); Console.Write(""File Created"");

} else { Console.Write(""File already exists.""); } Console.ReadKey();

However, while executing the application, an error was generated. Analyze the code and provide the solution.""1, string fileName = ""Myfile.txt""; if (!File.Exists(@""D:\"" + fileName)) { FileInfo fi = new FileInfo(@""D:\"" + fileName); File fs = fi.Create(); fs.Close(); Console.Write(""File Created"");

} else { Console.Write(""File already exists.""); } Console.ReadKey();""2, string fileName = ""Myfile.txt"";

Page 41: 56310957-semc-UML

if (!File.Exists(@""D:\"" + fileName)) { FileInfo fi = new FileInfo(); FileStream fs = fi.Create(); fs.Close(); Console.Write(""File Created"");

} else { Console.Write(""File already exists.""); } Console.ReadKey();""3, string fileName = ""Myfile.txt""; if (!File.Exists(@""D:\"" + fileName)) { FileInfo fi = new FileInfo(@""D:\"" + fileName); FileStream fs = fi.Create(); fs.Close(); Console.Write(""File Created""); } else { Console.Write(""File already exists.""); } Console.ReadKey();""4, string fileName = ""Myfile.txt""; if (!File.Exists(""D:\"" + fileName)) { FileInfo fi = new FileInfo(""D:\"" + fileName); FileStream fs = fi.Create(); fs.Close(); Console.Write(""File Created"");

} else { Console.Write(""File already exists.""); } Console.ReadKey();" 3120 "You wanted to create an application that serializes the company name and the employees' name into an XML format and stores in an XML file, Company.xml. In addition, the application should deserialize the company name and the employees' name and display it on the screen. For this, you wrote the following code snippet:

Line 1: static void Main(string[] args)Line 2: {Line 3: string fileName = ""D:\\Company.xml"";Line 4: XmlSerializer xs = new XmlSerializer(typeof(company));Line 5: TextWriter tw = new StreamWriter(fileName);Line 6: company c = new company();Line 7: c.CompanyName = ""LargeSouk, Inc."";Line 8: Employee emp1 = new Employee();Line 9: Employee emp2 = new Employee();Line 10: emp1.name = ""Kelly"";Line 11: emp2.name = ""Sam"";Line 12: c.emp = new Employee[2] { emp1, emp2 };

Page 42: 56310957-semc-UML

Line 13: xs.Serialize(tw, c);Line 14: tw.Close();Line 15: FileStream fs = new FileStream(fileName, FileMode.Open);Line 16: company cmp = Deserialize(fs);Line 17: Console.WriteLine(cmp.CompanyName);Line 18: foreach(Employee e in cmp.emp)Line 19: {Line 20: Console.WriteLine(""{0}"",e.name);Line 21: }Line 22: Console.WriteLine(""\n Press Enter to exit.............."");Line 23: Console.ReadLine();Line 24: }

However, while executing the application, an error was generated. Analyze the code and provide the solution." "1, The Line 4 should be: XmlSerialization xs = new XmlSerialization (typeof(company));" "2, The Line 5 should be:TextWriter tw = new StreamWriter();" "3, The Line 15 should be: FileStream fs = new FileStream(FileMode.Open);" "4, The Line 16 should be:company cmp = (company)xs.Deserialize(fs);" 4


Recommended