98-361 Exam - Microsoft MTA Software Development Fundamentals

certleader.com

Q1. You are developing an ASP.NET applications that calls Web service to retrieve earthquake predictions for a given geographical area. The Web service performs complex, time-consuming calculations to generate the predictions. It is hosted on government Web server, where you have permission only to invoke the Web service. The users of your Web application complain that the user interface freezes when they attempt to retrieve the perditions. You have full access to the Web server that hosts your ASP.NET application. Which of the following approach should you use to resolve this issue? 

A. Move the ASP.NET application to a faster computer. 

B. Connect to the Web service over faster Internet connection. 

C. Install additional memory on the Web server that hosts the ASP.NET application. 

D. Use asynchronous calls to invoke the Web service from within your ASP.NET application. 

Answer:

Q2. You are developing code that defines an InitFields method. The method takes two parameters of data type double and does not return any value to the calling code. Which of the following code segments would you use to define the InitFields method? 

A. public double InitFields(double l, double w) 

length = l; 

width = w; 

return length * width; 

B. public void InitFields(double l, double w) 

length = l; 

width = w; 

C. public void InitFields(double l) 

length = l; 

width = l; 

return; 

D. public double InitFields(double l, double w) 

length = l; 

width = w; 

Answer:

Q3. Which of the following languages is not considered a high-level programming language? 

A. C# 

B. Visual Basic 

C. Common Intermediate Language 

D. C++ 

Answer:

Q4. You are writing a method named PrintReport that doesn't return a value to the calling code. Which keyword should you use in your method declaration to indicate this fact? 

A. void 

B. private 

C. int 

D. string 

Answer:

Q5. You are developing an algorithm before you write the C# program. You need to perform some calculations on a number. You develop the following flowchart for the calculation: 

If the input value of n is 5, what is the output value of the variable fact according to this flowchart? 

A. 720 

B. 120 

C. 24 

D. 6 

Answer:

Q6. You are developing an algorithm for a retail Web site. You need to calculate discounts on certain items based on the quantity purchased. You develop the following decision table to calculate the discount: 

If a customer buys 50 units of an item, what discount will be applicable to the purchase? 

A. 5 percent 

B. 10 percent 

C. 15 percent 

D. 20 percent 

Answer:

Q7. You are developing an ASP.NET applications that calls Web service to retrieve inventory information. You know the URL of the Web service. You need to invoke the methods of this Web service within your Web application. How can you generate the client-side proxy classes so that you can use the Web methods? 

A. Use the Web service discovery tool. 

B. Copy the .ASMX file from the Web server to the ASP.NET application project. 

C. Copy the build output from the Web server to the ASP.NET application project. 

D. Set a Web reference to point to the Web service. 

Answer:

Q8. You need to provide complex multi-way branching in your C# program. You need to make sure that your code is easy to read and understand. Which of the following C# statements should you use? 

A. case 

B. break 

C. if-else 

D. switch 

Answer:

Q9. You need an application that updates the inventory every morning when you log in to the workstation. If an error occurs during update, the application needs to log messages to a text file. The application doesn’t need any user interaction. You want to automate the process that launches the application. You want to minimize the efforts for developing, installing, and updating the application. Which type of application should you create? 

A. Windows Service 

B. Windows Form 

C. Web Form 

D. console application 

Answer:

Q10. Your application includes a SqlDataAdapter object named sqlDataAdapter and an OleDbDataAdapter object named oledbdataAdapter. You need to connect to the Employees table of a SQL Server database. Your application also includes a DataSet object named dsEmployees. You need to load the data from the database into the DataSet object. You must select a solution that gives you the best performance. Which of the following lines of code should you choose? 

A. dsEmployees = sqlDataAdapter.Fill(“Employees”); 

B. dsEmployees = oledbDataAdapter.Fill(“Employees”); 

C. oledbDataAdapter.Fill(dsEmployees, "Employees"); 

D. sqlDataAdapter.Fill(dsEmployees, “Employees”); 

Answer: