Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

C# Questions: 1. BinarySearch() is ____. A. Usable as long as you declare an array B. A method in the Array class C. Must be

C# Questions:

1. BinarySearch() is ____.

A. Usable as long as you declare an array

B. A method in the Array class

C. Must be used with integer arguments

D. An instance method

2.

int [ ] anArray = new int [10];

int [ ] anotherArray = {6, 7, 4, 5, 6, 2, 3, 5, 9, 1};

foreach (int val in anotherArray)

total += val;

Using the above declaration along with the foreach loop, what is stored in total after the program statements are executed?

A. 48

B. 10

C. 45

D. 2

3. To declare and instantiate memory for 4 test scores that range in value from 0 to 100, the following declaration could be made ____.

A. Int testScore = new testScore[3];

B. Int testScore[4] = new testScore[ ];

C. Int[ ] testScore = new testScore[4];

D. Int[ ] testScore = new testScore[3];

4. When you use the assignment operator with an array, individual elements are copied to another memory location.

True

False

5. Properties are added to a class to enable client applications to access public members.

True

False

6. C# has two types of string literals. The @-quoted string literals are called ____.

A. Actual string literal

B. Quoted string literal

C. At string literal

D. Verbatim string literal

7. C# uses a row major format for accessing arrays, which means that the elements are printed in rows. Every entry in the first column is printed before moving to the second column.

True

False

8. In order to determine the position of one or more characters inside a string argument, use the ____ method of the string class.

A. Place( )

B. IndexOf( )

C. Location( )

D. Position( )

9.

int [ , , ] anArray = new [3, 2, 7] allows ____ elements to be stored.

A. 3

B. 42

C. 7

D. 12

10. The method in the string class that returns the string in uppercase is ____.

A. ConvertToUpper( )

B. Upper( )

C. StringUpper( )

D. ToUpper( )

11. One of the guidelines for good design is to try to place as many controls on the form as you are able to without overlapping any.

True

False

12. How does a Windows application differ from a console-based application?

A. Unlike Windows applications, console-based applications do not access from the hard drive

B. Windows applications do not have a Main() method.

C. No looping is found with Windows applications.

D. Windows applications sit in a process loop, once executed, waiting for an event to execute.

13. To have the ListBox or ComboBox Items arranged in alphabetical order ____.

A. The values must be originally type in the desired order

B. Set the Ordered property to ascending or descending

C. Use a drag and drop approach move the items into their correct order

D. Set the Sorted property to true

14. Which property is used with the PictureBox control to associate an actual picture to the control?

A. Picture

B. Icon

C. Image

D. Resource

15. ComboBox objects save space on a form through their use of a predefined size property.

True

False

16. Which of the following class has public constructors?

A. StreamReader

B. TextReader

C. File

D. Stream

17.

StreamWriter outputFile = new StreamWriter("someOutputFileName");

StreamReader inputFile = new StreamReader("someInputFileName");

The identifier that can be referenced in a WriteLine( ) method with the declaration above is ____.

A. someInputFileName

B. someOutputFileName

C. inputFile

D. outputFile

18. None of the of the method named in the File and Directory classes are available as instance methods (with the same name) in the FileInfo and DirectoryInfo classes since they are available in File and Directory.

True

False

19. All of the following are core classes that make up the ADO.NET data providers EXCEPT ____.

A. Connection

B. DataReader

C. Command

D. DataSet

20. When accessing data from a database, select the records (and fields) from the database by executing a SQL Fill statement.

True

False

21. The Data Source Configuration Wizard simplifies connecting your application to a data source by guiding you through the process, automatically generating the connection string, creating dataset and table adapter objects, and bringing the data into your application.

True

False

22. A data reader class allows read-only forward retrieval of data from the database.

True

False

23. XHTML Directives are delimited with <% and %>.

True

False

24. Two files are created for each page when you build Web applications. This file ending in .aspx holds the HTML tags.

True

False

25. Selecting HTTP for the File Location, stores files, by default, in the C:\Inetpub\wwwroot directory.

True

False

26. Which of the following is an example of a scripting language that might be used to create a dynamic web page?

A. C# Script

B. C Script

C. JavaScript

D. All of the above

27. What is one of the major differences between an ASP .NET application that you build and a Windows application?

A. You can drag and drop controls onto the Windows form

B. Windows applications are event driven applications

C. Two separate files are created for the user interface for Web applications

D. All of the control classes are organized under a common namespace for Windows applications

28. Style sheet includes a list of rules. Each rule consists of ____.

A. A tag and an attribute

B. One or more property

C. A selector and one or more declaration blocks

D. An outline body

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Building Database Driven Catalogs

Authors: Sherif Danish

1st Edition

0070153078, 978-0070153073

More Books

Students also viewed these Databases questions

Question

=+ At what rate does capital per person grow?

Answered: 1 week ago