1. Trang chủ
  2. » Thể loại khác

các câu trả lời của BTNT

38 2.7K 2

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Question of 20 The default integral number type is 5.0/ 5.0 Points A short B long C byte D int Question of 20 In the following code sample, will the second if structure be evaluated? bool condition = true; if(condition) if(5 < 10) Console.WriteLine("5 is less than 10); 5.0/ 5.0 Points True False Question of 20 float type variable size is A 32 bits B 48 bits C 64 bits 5.0/ 5.0 Points D 24 bits Question of 20 how many number is created while compilation with the declaration below: byte b = -1; 5.0/ 5.0 Points A B C D compile error Question of 20 character type variable size is 5.0/ 5.0 Points A bits B bits C bits D 16 bits Question of 20 implicite integral number initialization casting order is 5.0/ 5.0 Points A ulong long uint int B int long uint ulong C uint int ulong long D int uint long ulong Question of 20 byte type variable size is 5.0/ 5.0 Points A 12 bits B bits C 24 bits D 16 bits Question of 20 A variable declared inside a method is called a variable A Static B Serial 5.0/ 5.0 Points C Local D Private Question of 20 A String literal is a: 5.0/ 5.0 Points A sequence of characters in double quotation marks B contains exactly its variable name and nothing else C contains numbers rather than letters D only contains one character Question 10 of 20 byte type variable range is 5.0/ 5.0 Points A 0-255 B -128 +127 C – 127 Question 11 of 20 using System; class Test { public static void Main() 5.0/ 5.0 Points { int value =Int32.Parse(""99953""); double dval=Double.Parse(""1.3433E+35""); Console.WriteLine(value); Console.WriteLine(dval); } }; What will be the output of above code when compiled/run? A The output of above code will be 99953 1.3433E+35 B The output of above code will be 99953 1.3433E35 C The code will generate a runtime error D The code will generate a compile time error Question 12 of 20 double type variable precision is A 16-17 digits B 12-13 digits C 14-15 digits 5.0/ 5.0 Points D 15-16 digits Question 13 of 20 What are the keywords supported in an if statement? 5.0/ 5.0 Points A if, else, else if, break B if, else, else if C if, else, default D if, else, else-if, return Question 14 of 20 The _ namespace provides the classes and methods for manipulating arrays 5.0/ 5.0 Points A System.IO B System.Array C System.Arr D Array Question 15 of 20 What is the purpose of break;in a switch statement? A It causes the program to pause 5.0/ 5.0 Points B It causes the program to exit C It causes the code to exit the switch statement D It causes the code to stop executing until the user presses a key on the keyboard Question 16 of 20 double type variable range is 5.0/ 5.0 Points A from ±5.0E−324 to ±1.7E308 B from ±1.7E−320 to ±1.7E320 C about ±1.5.0E±256 D from ±5.0E−256 to ±1.7E320 Question 17 of 20 how many number is created while compilation with the declaration below: short s = 1; A B C D Question 18 of 20 5.0/ 5.0 Points class Test{ static void Main() { int[] Array1= {3,2,1}; int i=Array.IndexOf(Array1,3); Console.WriteLine(i); } } What will be the output of above code A B C D Question 19 of 20 Namespaces are defined using _ statements 0.0/ 5.0 Points A Namespace B Using C System D Class Question 20 of 20 short type variable size is 5.0/ 5.0 Points A 12 bits B bits C 16 bits D 24 bits 0.0/ 5.0 Points Question of 20 If the Employee class inherits from the Person class, covariance lets you which of the following? A Store a method that returns an Employee in a delegate that represents methods that return a Person B Store a method that takes a Person as a parameter in a delegate that represents methods that take an Employee as a parameter C Store a method that returns a Person in a delegate that represents methods that return an Employee D Store a method that takes an Employee as a parameter in a delegate that represents methods that take a Person as a parameter Question of 20 Suppose the variable note is declared by the statement Action note Then which of the following correctly initializes note to an expression lambda? A note = () => MessageBox.Show("Hi"); 5.0/ 5.0 Points B note = () { return x * x; }; C note = { return x * x; }; D note = MessageBox.Show("Hi"); Question of 20 If the Employee class inherits from the Person class, contravariance lets you which of the following? 0.0/ 5.0 Points A Store a method that takes an Employee as a parameter in a delegate that represents methods that take a Person as a parameter B Store a method that takes a Personas a parameter in a delegate that represents methods that take an Employee as a parameter C Store a method that returns a Person in a delegate that represents methods that return an Employee D Store a method that returns an Employee in a delegate that represents methods that return a Person 5.0/ 5.0 Points Question of 20 Suppose you want to sort the Recipe class in question by any of the properties MainIngredient, TotalTime, or CostPerPerson In that case, which of the following interfaces would probably be most useful? A Idisposable B Isortable The _ encloses the statements that might throw an exception whereas catch handles an exception if one exists A Catch B Try C Exception D Finally Question 12 of 20 5.0/ 5.0 Points _ block is executed after try block regardless of the occurrence of error _ block contains all cleanup codes For example, if there is no need of open connection to the database after try block we can write code for connection close in _ block A Try B Exception C finally D Catch Question 13 of 20 5.0/ 5.0 Points Can multiple catch blocks be executed for a single try statement? In other words can code inside multiple catch blocks be executed A No B under certain conditions C Yes Question 14 of 20 5.0/ 5.0 Points Exception objects are derived from the class A Event B Try C Catch D Exception Question 15 of 20 5.0/ 5.0 Points A method _an exception when that method detects that a problem has occured A Trys B a and b C Catches D Throws Part of - Part Question 16 of 20 20.0/ 25.0 Points 5.0/ 5.0 Points Select a collection type that match all condition bellow : Represents a collection of key/value pairs that are organized based on the hash code of the key A weakly typed collection of key-value pairs Lets you quickly get an object out of the collection by using it's key Access items in your weakly typed collection, based on a key, not on an index Each element is a key/value pair stored in a DictionaryEntry object A Queue Class B Stack Class C Array class D HashTable Class Question 17 of 20 The Syntax of a predefined Sort method is: A Arraytosort.Array.Sort() B Arraytosort.Sort() C System.Array.Sort() 5.0/ 5.0 Points D System.Array.Sort(Arraytosort) Question 18 of 20 5.0/ 5.0 Points How can you sort the elements of the array in descending order? A By calling Sort() and then Reverse() methods B By calling Descend() C By calling SortReverse() D By calling ReverseSort(); Question 19 of 20 0.0/ 5.0 Points Select a collection type that match all condition bellow : It is useful for storing messages in the order they were received for sequential processing it maintains FIFO (first in first out) system With it you can create weakly typed collections that are ordered by the order they are added to the collection It accepts a null reference as a valid value and allows duplicate elements Objects stored in it are inserted at one end and removed from the other A Stack Class B HashTable Class C Array class D Queue Class Question 20 of 20 5.0/ 5.0 Points Select a collection type that match all condition bellow : It is One of the most basic collection classes It's not really a collection class, due to its limitations and its not even located in the System.Collections namespace, but in the System namespace It has a fixed size it can have multiple dimensions You can access an item of it by it's index A Stack Class B HashTable Class C Array class D Queue Class Question of 20 What are the weekness of typed dataset A.Hight performance B.Heavy object C.No re-use/upgrade model D.Lack of DataAccess features 5.0/ 5.0 Points Question of 20 What are the valid parrameter of connection string ? 5.0/ 5.0 Points A.DataSource B.Initial catalog C.Integrated security D.Connection timeout Question of 20 How to get a DataReader object from Command object? 5.0/ 5.0 Points A Command.GetReader() B Command.GetAllReader() C Command.ExecuteReader() Question of 20 Database connectivity with ADO has main objects: A ADODB.Connection B All of the above 5.0/ 5.0 Points C ADODB.Command D ADODB.Recordset Question of 20 What is a connection object? 5.0/ 5.0 Points A Specifies whether to use a DSN or DSN-less connection B First opens the initial connection to a database before giving any database information C Specifies the type of driver to use, database format and filename D Specifies whether to use a DSN or DSN-less connection 5.0/ 5.0 Points Question of 20 Which of the following Namespace is used for better performance when connecting to SQLServer ? A System.Data.SQLClient B System.Data.OracleClient C System.Data D System.Data.Oledb Question of 20 5.0/ 5.0 Points Which of the following statements is true about Dataset ? A Dataset cannot store any tables in the cache B Dataset can store only one table in its cache C Dataset stores tables in the cache,only when cache set to true D Dataset can store multiple tables in cache Question of 20 Optimistic concurency means 5.0/ 5.0 Points A control works on the assumption that resource conflicts between multiple users are unlikely (but not impossible), and allows transactions to execute without locking any resources Only when attempting to change data are resources checked to determine if any conflicts have occurred If a conflict occurs, the application must read the data and attempt the change again B … control locks resources as they are required, for the duration of a transaction Unless deadlocks occur, a transaction is assured of successful completion C ….whatever data modification was made last gets written to the database Question of 20 How many types of Concurrency handling techniques in ADO.NET ? A B 5.0/ 5.0 Points C D Question 10 of 20 How to roll back all changes that have been made to the table since it was loaded? 5.0/ 5.0 Points A Call DataTable.RollbackChanges() method B Call DataSet.RejectChanges() method C Call DataTable.RejectChanges() method D Call DataSet.RollbackChanges() method Question 11 of 20 Which object of ADO.NET has the best performance for retrieving the data 5.0/ 5.0 Points A DataReader B Dataadapter C DataSet D Data Provider Question 12 of 20 5.0/ 5.0 Points What must your ASP code have if you are using the DSN method of connecting? A Both B Connection string C Connection object Question 13 of 20 Which method of DataTable can be used to return all changed rows since it was last loaded? 5.0/ 5.0 Points A GetUpdated() B FindChanges() C GetChanges() D GetChanged() 5.0/ 5.0 Points Question 14 of 20 OLEDB Connection Pooling is handled by OLEDB.Net Provider and SQLClient Connection pooling is handled by A Windows 2000 Component Service B ODBC provider C OLEDB Provider D SQL Provider Question 15 of 20 What are the keys to describe exactly about "DataReader" object? 5.0/ 5.0 Points A.Forward only B.Faster access C.Connected mode D.Read-only Question 16 of 20 Can a dataset be returned by connecting Excel file as database? 5.0/ 5.0 Points True False Question 17 of 20 Chose valid value for datarowstates ! A.Modified B.Detached C.Deleted 5.0/ 5.0 Points D.Added 5.0/ 5.0 Points Question 18 of 20 You use a TransactionScope in your application in your application in order to use transaction semantics What code should you use in order to commit the transaction within the transaction scope? A TransactionScope.Commit(); B TransactionScope.Completed = true; C TransactionScope.IsCompleted = true; D TransactionScope.Complete(); Question 19 of 20 Which object that bellowed statements describe about? Its is Read only ! Its connected to datasource You must manage connection your self It use fewer server resource 5.0/ 5.0 Points A DataReader B Dataset C DataTable D DataView Question 20 of 20 5.0/ 5.0 Points DataSet object contains : A.DataRow B.DataTable C.DataColumn D.DataRelation Question of 20 5.0/ 5.0 Points Which add dynamic property in mvc 3? A ViewData B ViewBag C ViewState D TempData Question of 20 How many routes can be defined in the mvc application? A three B one 5.0/ 5.0 Points C more than one D two Question of 20 5.0/ 5.0 Points What are Validation Annotations? A These attributes provide client-side validation, and the framework also supports clientside validation when you use one of the attributes on a model property You can use four attributes in the DataAnnotations namespace to cover the common validation scenarios, Required, String Length, Regular Expression and Range B These attributes provide server-side validation, and the framework also supports clientside validation when you use one of the attributes on a model property You can use four attributes in the DataAnnotations namespace to cover the common validation scenarios, Required, String Length, Regular Expression and Range C These attributes provide server-side validation, and the framework also supports serverside validation when you use one of the attributes on a model property You can use four attributes in the DataAnnotations namespace to cover the common validation scenarios, Required, String Length, Regular Expression and Range Question of 20 5.0/ 5.0 Points Can we use ASPX view engine in latest versions of MVC? True False Question of 20 ASP.NET MVC introduced a new ActionResult called HttpNotFoundResult 5.0/ 5.0 Points A B Question of 20 5.0/ 5.0 Points What is the syntax for server side comment in razor view? A // Comment here // B @* Comment here *@ C Question of 20 5.0/ 5.0 Points What are Code Blocks in Views? (Razor) A @{code commands here } B C @* code commands here *@ Question of 20 Which is the correct code to get the Name? A @foreach (var item in items) { 0.0/ 5.0 Points

Ngày đăng: 09/08/2016, 13:11

Xem thêm: các câu trả lời của BTNT

TỪ KHÓA LIÊN QUAN

w