DOT NET SE AD2 Question Answers


Hello friends if you are looking for DOT NET SE AD2 MCQ With Answers | DOT NET SE AD2 objective-type questions | DOT NET SE AD2 Question Answers Accenture Dumps | DOT NET SE AD2 Multiple Choice Questions | DOT NET SE AD2 Interview Question Answers

1) Consider a Data context class called EmployeeContext with a property called Employees of type
DbSet
Which of the following queues can be used to delete the details of an employee based on the
employee Id 101? The employee Id is the primary key in the database.

Ans) EmployeeContext context=new EmployeeContext();
var employee = context.Employees.Remove(context.Employees.Find(101);
2) Which of the following command needs to be changed in ADO.NET to specify that we are with
stored procedure?

Ans) cmdEmp.CommandType = CommandType.StoredProcedure;
3) Peter a developer who wants to perform the operation on set of records from database and
forward only mode. He wants to know which method of sql command to be executed to achieve the
same.

Suggest the suitable method for Peter to choose?
a)Execute Reader
b)ExecuteNonQuery
c)ExecuteScalar
d)ExecuteXmlReader

ans -a
4)Consider following code and identify the navigation properties of Entity data model Assumption:
Assumption : Employee and Dept are valid classes
public class Employee
{
public int EmpId { get; set; }
public string EmpName { get; set; }
public double Salary { get; set; }
publix Dept Dept { get; set; }
}

a) Empid
b) EmpName
c)Salary
d)Dept

Ans – d

5) john is a novice developer and he created the entity data model using database first approach He
is confused about which EDM layer stores the information like table views and stored procedures.
Help john in identifying the suitable layer ?

A) Storage Layer
B) Conceptual Layer
C) Storage Layer

Ans – a
6) Given a table ProductDetails(ProductID,ProductName,ProductPrice) in SQLServer.Choose
appropriate option to display count of products using EF where price is more than 1000.

Note : so is DataContext type and ProductDetails is of DbSet
option 1) var result = (from p in sce.ProductDetails count p ProductName where p ProductPrice >
1000 select p;
option 2) var result = (from p in sce ProductDetails
where p ProductPrice > 1000 select p) Count();
option 3) var result = (from p in sce ProductDetails
select p)Count(where p ProductPrice > 1000);
option 4) var result = (from p in sce ProductDetails
where p ProductPrice > 1000 count p);
7) John wants to know which Model generation approach in Entity FrameWork he can use so that he
wants to create the tables in database and then create EDM based on the tables ?

A) Database First
B) Code First
C) Model First

Ans – a


8) Consider the following LINQ program and fill in the missing code to display the output of result :
using System;
using System.Linq;
class LINQEx
{
static void Main(string[] args)
{
string[] accenture = { “HDC” , “BDC” , “CDC” };

var result = accenture.Select(location => location).COunt();
/ Missing code to print */
}
}
Ans) Console.WriteLine(result);

9) Consider a class called Employee and a generic list of employee instance called “employees”.What
will be the data type of the result variable shown in the following code snippet?
What will be the data type of the result variablw shown in the following code snippet ?
var result = from e in employees select e;

1) Employee[]
2) IEnumerable
3) EMployee
4) var

ans – 2


10) Which of the following LINQ API is used to connect and work with SQLSERVER
Choose most appropriate option

a) LINQ to Objects
b) LINQ to SQL (ans)
c) LINQ to XML
d) LINQ to Entities

ans – b


11) How will developer specify that a stored procedure is being called from ADO.NET?
Choose most suitable option
a) Setting the CommandText property of the SqlCommand object to “Text”
b) Setting the CommandType property of the SqlCommand object to “StoreProcedure”
c) Setting the CommandType property of the SqlCommand object to :Procedure”
d) The default setting for SqlCommand supports procedure calls.That need not be especially
specified for developers.

ans – b


12) Which of the following is used to connect and work woth Collections like arrayList etc ?
choose most appropriate option
a) LINQ to OBJECTS (ans)
b) LINQ to SQL

c) LINQ to XML
d) LINQ to ENTITIES

ans -a

13)Consider following code and identify the scalar properties of Entity data model Assumption:
Assumption : Employee and Dept are valid classes
public class Employee
{
public int EmpId { get; set; }
public string EmpName { get; set; }
public double Salary { get; set; }
publix Dept Dept { get; set; }
}

a) Only EMpId
b) Only EmpName
c) Both Dept and Project
d)Both Empid and EmpName

ans – d

14) John wants to know Which Model generation approach in Entity FrameWork he can use so that
he wants to create Model classes based on the designer tool and then based on this the database
will be created ?

Choose the most appropriate option
a)Code First
b)Database First
c) Model First

ans – c


15) What will be the output of the following LINQ program?
using System;
using System.Linq;
class SampleLambda
{
static void Main()
{

// Data Source
int[] scores = { 9, 7, 82, 85, 95, 2 };
int highScoreCount = scores.Where(number => number < 80).COunt();
Console.riteLine(highScoreCount);
}
}

a) 1
b) 4
c) 3
d) 6

ans – c

16) Which of the following object can store more than one table data and stores the information in
memory?

a) Data Table
b) DataSet
c) SqlDataAdapter
d) SqlCommand

ans – b
17)Which of the following LINQ syntax can be used to retrieve the contents of an integer array called
“numbers”, in descending order ?

a) from i in numbers orderby i descending select i
b) from i in numbers orderby descending i select i
c) from i in numbers orderby numbers descending
d) from i in numbers select i orderby i

ans -a


18)Consider the following code written in ADO.NET to retrieve the total number of records present
in employees table
public int GetEmpsCount()
{
connEmp.Open();
cmdEmp = new SqlCommand(‘select count() from employees’ connEmp); . code is missing*/connEmp.Close();
return count;
}

a) int count = Convert.ToInt32(cmdEmp.ExecuteSalary()); (ans)
b) int count = Convert.ToInt32(cmdEmp.ExecuteReader());
c) int count = Convert.ToInt32(cmdEmp.ExecuteNonQuery());
d) int count = cmdEmp.ExecuteScalar();

ans – a


19)connEmp.Open();
string cmdText = “Select * FROM Employees”;
SqlCommand cmdEmpDr = new SqlCommand(cmdText, connEmp);
SqlDataReader dr = cmdEmpDr.ExecuteReader();
dr.Read();
Console.WriteLine(“empid={0},empname={1}”,dr[0].ToString(),
dr[1].ToString());

a) 1
b) 15
c) 2
d) 8

ans – a


20) which of the following ado.net data provider is used to connect to excel file ?
a) ODBC
b) Oracle
c) SQL
d) OLEDB

ans – d
21) Which of the following command in SQL Server makes the updates performed by the Explicit
Transaction permanent in the database?

a) ROLLBACK
b) TRUNCATEc) SAVECHANGES
d) COMMIT

ans – d

22) Which of the following statements are TRUE about foreign key?

1.Foreign key can accept NULL values

2.Relationship between two table is established using foreign key
a) only 1
b) only 2
c) Both 1 and 2
d) Neither 1 NOR 2

ans – c
23) How Many primary keys can be there for a table ?
a) one
b)two
c) three

ans – a

24) Consider the EmployeePayHistory table structure as follows: EmployeepayHistory(EmployeeID
int primary key rate,int not null)
You need to display the total number of employees whose rate is 26.
How will you generate the required ressult ?

Ans) select count(employee_id)as totaal_no_of_employees from employee_pay_history where
rate=26
(AND)
select count(rate)as total_no_of_employees from employee_pay_history where rate=26
25) Consider a table “dept” is already created in SQL Server and you have decided to change the size
of one of the column of the table. Which of the following command will you use to achieve it?

a) Drop
b) Alter
c) Create
d) Delete

ans – b

26) Identify which of the following variables are global variables in SQL Server.
a) @@identity
b) @@Error
c) @value
d) @Data

ans – a b
27) What will be the output of the following program of LINQ ?
using System;
using System.Linq;
class LINQ1 {
static void Main(string[] args)
{
int[] array1 = {8, 4, 7, 3, 6, 1 };
var result = from number in array1 where (number % 2) == 0
orderby number descending
select number;
foreach (int value in result)
{
Console.Write(value + ” “);
}
}
}
a) 8 4 6
b) 7 3 1
c)8 4 7 3 8 1
d)8 6 4

28) In a table(CityID, CityName,ForeCastDate,TemperatureRecorded…..Ans) var result = from c in cwd.CityWeatherDetails
orderby c.TemperatureRecorded descending select c;
29)Consider a table employee with empname as one of its column and you want to fetch all
employees whose empname starts with ‘a’ and ends with ‘e’ character.
which of the following query can be used?

ans) select * from employee where ename like ‘a%e’;

31) create table Customer
(custId int primary key,custName varchar(50) not null,city varchar(50) check ( city
in(‘Banglore’,’Pune’,’Hyderabad’)))
statement 1:
insert into Customer values(1,null,’Pune’)
statement 2:
insert into Customer values(2,’Mark’,’Chennai’)
Ans) Both statements fails and no records gets added.

32) which of the following options can be used to retrieve the employee name and department
name of the employees who earn more than 50000?
ANS-Inner Join

33) assumption connemp is valid connection object, dr is a valid datareader object, cmdempdr is a
valid command object
ANS-15

1.consider a table ”dept” is already created in sql server and you have decided to change the size of
one of the column of the table . which of the following command will you use to achieve it?
Ans: (Alter)

  1. How many primary keys can be there for a table?
    Ans: (One) (primary key)
  2. Consider the employeepayhistory table structure as follows:
    You need to display the total number of employees whose rate is 26?
    Ans: A & B (count(Employee Id), count(Rate)
  3. john has been asked to create a stored procedure on the following table structure
    Ans: opt. B (@UserName VARCHAR(50) OUTPUT)
  4. Which of the following options can be used to retrieve the employww name and department
    name of the employees who can earn more than 50000?
    Ans: A (..inner join..)
  5. Identify which of the following variables are global variables in sql server?
    Ans: @@identity ,@@Encv
  6. Create table customer
    (banagalore, pune, huyderabad)
    Ans: Both statements are not executed
  7. you want to retrieve the name and price of a product from a table based on a unique id which
    method of the SQL command class can be used to perform this task?
    Ans: ExecuteReader
  8. Consider following code and identify the scalar properties of entity data model
    Assumption: employee, dept, project are valid classes
    Ans: EmpId, EmpName
  9. What will be the output of the following program in linq
    {8,4,7,3,6,1}
    Order number by descending
    Ans: 8 6 4
  10. Which of the following linq api is used to correct and work with collectors like array /list etc
    Ans: A
  11. Suggest the suitable method for Peter to choose?
    Ans: ExecuteReader 13.{9,7,82,85,95,2}
    Console.writeline(highscorecount);
    Ans: 3
  12. .{9,7,82,85,95,2}
    Console.writeline(highscorecount);
    Ans: 3
  13. John wants to know which model generation approach in entity framework he can use so that he
    wants to create model class based on the designer tool and then based on the database will be
    created ?
    Answer :model first
  14. Help John in identifying the suitable layer
    Answer : Storage layer
  15. Choose the above appropriate option to display temperature recorded in descending order
    Ans: A (order by c.TemperatureRecorded descending select c;)
  16. Consider a table employee with empname has one of its column and you want to fetch all
    employees whose empname starts with a and ends with E character
    Ans: a%e
  17. a view is created on the above table as follows
    create view bookdetails as select bookID, title, total pages from books
    Ans: view doesnot allow insert oper.
  18. Which of the following statements are true about foreign key
    1.foreign key can accept null values
    2.relation between two table is established using foreign key
    Ans: C (both 1 and 2)
  19. Consider you have created a stored procedure called ‘getemps’ in SQL Server and you need to
    specify this in your ado.net code so that command understands it needs to execute stored
    procedure which of the following code is correct in this regard
    Assumption: connemp is a valid SQL connection object,cmdemp is valid SQL command object
    Ans: A
  20. Select the code to be written to complete the above program
    Assumption: employees is a valid table in database, connemp is valid connection
    Object, amdemp is valid command object
    Ans: Commonobj.Execute scalar() 23. John is a novoice developer and he has created the entity data model using database first
    approach he is confused about which EDM layer stores the information like tables views and stored
    procedures help John in identifying the suitable layer
    Ans: storage layer
  21. How many records will the above code fetch
    Assumption : connemp is valid connection object, Dr is a valid datareader object ,CMDeMPDR is a
    valid command object
    Ans: 15
  22. which of the following object can store more than one table data and stores the information in
    memory
    Ans: B (Data set).
  23. which of the following link syntax can be used to retieve the contents of ana integer array called
    “numbers” in descending order
    Ans: A (…order by i….)
  24. which of the following linq api is used to connect and work with SQL server
    Ans: B (LINQ in Sql)
  25. Choose the appropriate option to display temperature recorded in descending order
    Answer: A
  26. vwBookdetails (bookid, titke) values(101. The sqlserver workshop)
    answer: records gets inserted to table
  27. peter is a novice developer who wants to perform the operation on set of records from database
    suggest a suitable method for peter to choose?
    Ans: Executereader
  28. given a table cityweatherdetails
    Ans: A
  29. you want to retrieve the name and price of a product from a table based on a unique product in
    which method of the SQL command classes can be used to perform this task?
    Ans: B
  30. john has been asked to create a stored procedure on the following table structure
    Users(userid int, username varchar(50))
    Assumption: userID is primary key user name is not null
    Ans: B
  31. Unknown
    Ans: both statement fails and no records get added 8. which of the following command in SQL server makes the updates performed by the explicit
    transaction permanent in the database?
    Ans: Commit
  32. which of the following ado.net data provider is used to connect the excel file
    Ans. OLEDB
  33. consider following code and identify the navigation properties off entity data model assumption:
    employee and dept are valid classes
    Ans: Dept
  34. which of the following linq api is used to connect and work with collections like arraylist etc
    Ans: LINQ to OBJECTS
  35. how will it developer specify that a stored procedure is being called from ADO.Net ?
    Ans: B
  36. consider a class called employee and generate list of employee instances called “employees”
    what will be the data type of the result variable shown in the following code snippet
    Ans: IEnumerable
  37. consider a data context class called employeecontext with the property called employees of type
    DBset
    Ans: B
  38. given a table productdetails
    Choose appropriate option to display count of products using EF where prices more than 1000
    Ans: B

Choose the appropriate option
a) LINQ to C#
b) LINQ to Entities
c) LINQ to Database
d) LINQ to XML

ans – a b c d

__ provides a means of reading a forward-only stream of rows from a SQL server database.
Fill in the blank with an appropriate option
a) SqlDataReader
b) Dataset
c) DataTable
d) Dataview
Answer: a
3.The goal of ____is to decrease the amount of code and maintenance required for data-oriented
applications

Choose the appropriate option
a) LINQ to C#
b) LINQ to Entities
c) LINQ to Database
d) LINQ to XML
Answer: b
4.A class source-code file that is compiled at run time. These classes can be: HTTP Module,
HTTP Handler. Can also be a code-behind file for an ASP.NET page or a stand-alone class file
containing application logic- find the extension of these files above
Choose most appropriate option
a) .config
b) .cs, .jsl, .vb
c) .licx, .webinfo
d) .resources, .resx
Answer: b

  1. Shruthi is working as a developer. She has to write the code to Create a ConnectionString.
    Which of the following parameter of ConnectionString she should use to specify the name of the
    database ?
    Choose two appropriate options.
    a) Provider
    b) Initial Catalog
    c) Database
    d) Data Source
    Answer: b c
    Rohit wanted to print the SQL server name of his system. Which code should use in SQL
    server name?
    Choose two most appropriate options.
    a) Select @@servername
    b) print@@servername
    c) select@@server
    d) print@@server
    Which of the following is true about ADO.NET?
    Choose most appropriate option.
    a) ADO.NET is an object oriented set of libraries that allows you to interact with data sources.
    b) ADO.NET classes are found in System.Data.dll.
    c) ADO.NET classes are integrated with XML classes.
    d) ADO.NET contains .NET Framework data provieder for connecting to a database.
    e) All of the above.
    LINQ relied on the concepts of extension of extension methods, anonymous types,
    anonymous methods and _____.
    Fill in the blank with an appropriate option.
    a) Lambda expressions
    b) Xml expressions
    c) Data expressions
    d) Sql expressions
    A/An _____ that does not have a WHERE clause produces the Cartesian
    product of the tables involved in the join. Choose the appropriate option
    a) Equi Join
    b) Inner Join
    c) Self Join
    d) Cross Join
    Arun wants to retrieve result using a query “select count(*) from employee”. Which is most
    appropriate SqlCommand method for his requirement
    Choose most appropriate option
    a) Execute Reader
    b) ExecuteQuery
    c) ExecuteNonQuery
    d) ExecuteScalar
    CREATE VIEW [dbo].[viewmyTable] AS SELECT D.DeptName, D.Location, E.Name FROM
    Department D LEFT OUTER JOIN Employee E ON D.DeptID = E.DeptID GO
    Predict the output, when the above query executed?
    Choose most appropriate option
    a) Commands execute successfully
    b) Incomplete query
    c) Syntax error
    CREATE VIEW [dbo].[viewmyTable] AS SELECT D.DeptName, D.Location, E.Name FROM
    Department D LEFT OUTER JOIN Employee E ON D.DeptID = E.DeptID GO
    Predict the output, when the above query executed?
    Choose most appropriate option
    a) Commands execute successfully
    b) Incomplete query
    c) Syntax error
    What is/are the advantages of LINQ over stored procedures?
    Choose most appropriate option.
    a)Debugging- it is really very hard to debug the stored procedure but as LINQ is part off .NET,
    you can use visual studio’s debugger to debug the queries.
    b)Deployment- With stored procedures, we need to provide an additional script for stored
    procedures but with LINQ everything gets compiled into single DLL hence deployment
    becames easy.
    c)Type Safety- LINQ is type safe, so queries errors are type checked at compile time.it is really
    good to encounter an error when compiling rather than runtime exception
    d)All off the above
    Answer: d
  2. which of the below are valid Statements about DataReader and Data set
    Choose most appropriate option.
    a) DataReader reads all the the records at a time and it is used in multiple databbbases.
    b) DataSet always reads one record at a time and it moves into a forword direction.
    c) DataReader is a connected Architecture
    d) Dataset is a collection of in memory tables
    Answer:c,d
    All query operations of LINQ consist of three district actions
    Choose most appropriate option.
    a) 1. Obtain the data source 2. Declare the Data source 3.Excute the data source
    b) 1. Declare the data source 2.Initialize the query 3. Execute the query c) 1. Declare the Data source 2. Create the data source 3 .Execute the Data source
    d) 1. Obtain the data source 2.Create the query 3. Execute the query
    Answer:d
    89._______is a pre defined, reusable routine that is stored in adatabase Fill the blank with most appropriate option. a) Function b) Stored Proccedure c) View d) Joins Answer:b In LINQ , all the core types are defined in _____
    Choose most appropriate option.
    a) System.Linq.XML and System.Linq.Expressions
    b) System.Linq and System.Linq.XML
    c) System.Linq and System.Linq.Expresssions
    d) System.XML.Linq and System.Linq.Expressions
    CREATE VIEW [dbo].[viewmyTable] AS SELECT D.DeptName , D.Location , E.Name FROM
    Department D JOIN Employee E ON D.DeptID = E.DeptID GO Predict the output , when the
    above view is executed ?
    Choose most appropriate option
    a) A view will be created by selecting deptname , location from the department table and
    employees name from the employee table .
    b) Syntax error
    c) Incomplete query
    d) A view will be created by selecting deptname , location and name from the department
    table.
    Answer : A
    VIEW [dbo].[viewmyTable] AS SELECT D.Deptname,D.location ,E.Name FROM
    Department D FULL OUTER JOIN Employee E ON D.DeptID = E.DeptID
    Whats the output , when the above query is executed?
    Choose most appropriate option
    a) Display all the employees with their Departments .Output contains
    b) The employee names and all the department names present in the database
    c) Syntax error
    d) Incomplete Query
    In ADO.net to manage data in dissconnected mode
    Ans:-SQL Data Adapter
    16)Which SQL data types should be used to hold unicode char?
    Ans:- I think it is NCHAR-not sure
    17)2 fundamental objects in ADO.Net?
    ANS:SQLConnection
    SQLCommand

Which of the following is an SQL command? (Select the best option)
a. INSERT
b. COMMIT
c. UPDATE
d. DELETE

e. All of the above
E) Correct. All are valid SQL commands.
64) SELECT *
FROM Customers
WHERE Phone LIKE ‘6_6%’
Which Customer Phone column will be selected when the above query is executed? (Select
the
best option)
a. 626 362-2222
b. 416 626-6232
c. 623 455-6545
d. All of the above
A) Correct. The underscore ‘_’ wildcard matches any single character in that particular
position. The
percentage sign ‘%’ matches to any number of characters in that specific position. Only
option A
satisfies this requirement for ‘6_6%’.

65) Which of the following “ORDER BY” clauses displays the result in a
descending order by
the attribute salary? And, if two records have the same attribute value for salary the
sorting
criteria is in an ascending order by the attribute value for job_id? (Select the best
option)
a. ORDER BY salary DESC and job_id ASC
b. ORDER BY job_id ASC and salary DESC ASC
c. ORDER BY salary DESC, job_id ASC
d. ORDER BY job_id ASC, salary DESC
e. None of the above
A) Correct. This option will display records of salary sorted in descending order with a
secondary sort
by job_id in ascending order.
Explanation for Faculty:
Order By clause is used to sort data selected from the table in a specified order and can only
be used
in SELECT statements. The syntax is “ORDER BY columns ASC|DESC”. By default, it is set
to
ascending order.

66)
1 Select savings account
2
3 Update savings account
4
5 Select checking account to update
6
7 Update selected checking account with the values from the savings account
8

Given the above pseudo code that transfers funds from a savings account to a
checking
account, where would you add a COMMIT statement to complete the transaction?
(Select
the best option)
a. After line 1
b. After line 3

c. After line 5
d. After line 7
A) Correct. Usually a commit statement is added only when all series of commands (or the
whole
complete transaction) is finished.

67) Which statement about SqlDataReader in ADO.NET is true?
a. It is the most efficient object in ADO.Net for quickly reading data
b. Data can be read only in a forward stream of rows
c. .ExecuteReader method of SqlCommand object is used to create a
SqlDataReader
d. All of the above
A) Correct. All of the above statements for SqlDataReader are correct

68) Which of the following is true about ADO.NET?
a. Is an object – oriented set of libraries that allow you to interact with data sources
b. Classes are found in System.Data.dll
c. ADO.Net classes are integrated with XML classes
d. Contains .Net framework Data providers for connecting to a database
e. All of the above
A) Correct. All of the statements about ADO.Net are true.
69) What is SQL (Structured Query Language)? (Select the best option)
a. A software problem
b. A structured way of validating the requirements and ensuring that the solution meets the
expectations
c. A standard interactive and programming language for getting information from and
updating a database
d. All of the above
C) Correct. SQL has become an industry standard for creating, updating and querying
database
management systems.

70) With SQL, how do you select a column named “FirstName” from the table
named
“Persons”? (Select the best option)
f. Extract FirstName from persons
g. SELECT Persons.FirstName
h. SELECT FirstName from Persons
i. None of the above
C) Correct. The syntax for the Select command is “SELECT column FROM table”.

71) Which of the following is true about SQL statements? (Select the best option)
a. SQL statements are not case sensitive
b. SQL statements can be on one or more lines
c. SQL statements are optionally ended with “;”
d. All of the above
e. None of the above
D) Correct. All of the statements are true.
71) Character strings and dates in the Where clause must be enclosed in: (Select the

best
option)
k. Single Quotation marks (‘)
l. Parenthesis
m. Double Quotation marks (“)
n. None of the above

A) Correct. Single quotation marks are used to enclose characters, strings and dates.

72) Which SQL statement is used to insert new data in a database? (Select the best
option)
a. Add New
b. Add Record
c. Insert Into
d. Insert New
e. None of the above
C) Correct. Insert Into is the only command for inserting data.

73) In SQL, how do you select all the records from a table named “Persons” where
the value
of the column “FirstName” is “Peter”? (Select the best option)
f. SELECT [all] FROM Persons WHERE FirstName=’Peter’
g. SELECT * FROM Persons WHERE FirstName=’Peter’
h. SELECT * FROM Persons WHERE FirstName LIKE ‘Peter%’
i. SELECT [all] FROM Persons WHERE FirstName LIKE ‘Peter’
B) Correct. This option retrieves records from the Persons table with Peter as the firstname.

74) Which SQL keyword is used to sort the result-set? (Select the best option)
f. Group By
g. Arrange By
h. Order By
i. Sort By
C) Correct. ‘ORDER BY’ is the best keyword used to sort either by ascending or descending.
75) Which statement is used to change “Hansen” into “Nilsen” in the “LastName” column in
the
Persons table? (Select the best option)
a. UPDATE Persons SET LastName=’Hansen’ INTO LastName=’Nilsen’
b. MODIFY Persons SET LastName=’Hansen’ INTO LastName=’Nilsen
c. UPDATE Persons SET LastName=’Nilsen’ WHERE LastName=’Hansen’
d. MODIFY Persons SET LastName=’Nilsen’ WHERE LastName=’Hansen’
C) Correct. This option contains the correct syntax for updating rows in a table.

76) Which of the following are Transaction Control statements? (Select the best
option)
a. Commit
b. Rollback
c. Order By
d. A & B
e. All of the above
A) Correct. Both Commit and Rollback are transaction control statements. Commit is used to
commit
the current transaction, making all the previous changes permanent, while rollback aborts
the
current transaction, discarding all the updates of that particular transaction.

77) Which of the following is an ADO.NET Data provider (Select the best option)
a. OleDb Data Provider
b. ODBC Data Provider
c. Oracle Data Provider
d. SQL Data Provider
e. All of the above
E) Correct. All of the above listed data providers are ADO.NET data providers.

78) Match the concepts in the list on the right with their correct descriptions.
b 1) Retrieves a single value (for example, an

aggregate value) from a database

a) ExecuteXmlReader
d 2) Executes commands that return rows b) ExecuteScalar
c 3) Executes commands such as Transact-SQL
INSERT, DELETE, UPDATE statements

c) ExecuteNonQuery
a 4) Sends the CommandText to the Connection and
builds an XmlReader object

d) ExecuteReader
Feedback:
A) ExecuteScalar retrieves a single value (for example, an aggregate value) from a database
B) ExecuteReader executes commands that return rows
C) ExecuteNonQuery executes commands such as Transact-SQL INSERT, DELETE,
UPDATE, and
SET statements
D) ExecuteXmlReader sends the CommandText to the Connection and builds an XmlReader
object.

79) Which of the following is the correct Connection string format used for
connecting a SQL
Server Database? (Select the best option)

f. SqlConnection conn = new SqlConnection(“Data Source = DatabaseServer;
Initial Catalog=Northwind;User ID = YourUserID ; Password
=YourPassword”);

Which method of the DbCommand object executes a DML statement against a connection
and returns
the number of rows affected?
ExecuteReader()
CreateObjRef()
ExecuteNonQuery()
ExecuteScalar()
ANSWER 3
InsertCommand ,UpdateCommand and DeleteCommand properties are available in
_______ object.
DataAdapter
DataReader
DataSet
Command
ANSWER 1
————————————–__ enables you to create different views data from the Datatable object.


DataAdapter
DataSet&lt
DataView&lt
Command&lt
ANSWER 3
———————————Which of the following components of a data provider is used to retrieve, insert, delete, or
modify data
in a data source?
Connection
Command
DataReader
DataAdapter
ANSWER 2
——————————————A _________ subquery executes as many times as the inner query executes.
Subquery with the ANY clause.
Subquery with the ALL clause.
Subquery with the IN clause.
Non-corelated.
Co-related
ANSWER 5
What are the different components of LINQ?
Choose four appropriate options.
a) LINQ to Objects
b) LINQ to XML
c) LINQ to SQL
d) LINQ to DataSet
e) LINQ to Datatable
f) LINQ to DataRow
Answer: a b c d
The goal of ____is to decrease the amount of code and maintenance required for data-oriented
applications
Choose the appropriate option
a) LINQ to C#
b) LINQ to Entities
c) LINQ to Database
d) LINQ to XML
Answer: b
Which is the top .NET class from which everything is derived?
Choose most appropriate option
a) System.Collections
b) System.Globalization
c) System.Object
d) System.IO
Answer : C

which of the following LINQ API is used to connect and work with sql server –>
LINQ to SQl.

which property of the DATA Table returns a collection of objects which contains
all the rows of the DATA Table –> Rows Psop.

Which of the following statements are TRUE about foreign key?
1.Forriegn key can accept NULL values.
2.Relationship between two tables is established using foregin key –> BOTH 1
and 2.

Create table Employee
(EmpId int primary key identity(1,1) ,EmpName varchar(50) not null,
city varchar(50) check ( city in (‘Bangalore’,’pune’,’Hyderabad’)))
statement 1:
insert into Employee values(1,’Robert’,’pune’)
statement 2:
insert into Employee values(null,’chennai’)
Assumption:Employee table doesnot have any records ——> 1-True,2-False.

which of the following ado.net data provider is used to connect to Excel file.
—> OLEDB
6.EmployeePayHistory (EmployeeID int primary key, rate int not null)
you need to display the total number of employees whose rate is 26.
how will you generate the require result?——> A.selectcount(EmployeeID) AS
total.. B.select count(rate) as’total….[A&B].

public class EMployee{
public int EMPId {get;set;}
public string EmpName{get;set;}
public Dept Dept{get;set;}
public Project project{get;set} —-> Both EmpId and EmpName.

Dataset is a collection of which of the following? –> Tables.

You want to retrieve the name and price of a product from a table based on a
unique product id which method of the SqlCommand class can be used to perform this
task? —> SQL DataReader

Table Name: Books
create view vwBookDetails
As
Select Bookid, title, totalpages from books
insert into vwBookDetails(bookid,title) values (101,’the sqlserver workshop’);
Assumption: NO records are present in the table
——> Record gets inserted to tables.

Choose the correct SQl query to fetch details of employees from employee table
and whose EmpName ends with an alphabet ‘a’ and has second letter as ‘r’.
—> Select * From Employee where EmpName Like ‘_r%a’

which of the following object can store more than one table data and stores the
information in memory —> Dataset.

Consider a table “dept” is already created in SQlServer and you have decided to
change the size of one of the column of the table. —-> Alter.

Jhon is a novice developer and he created the entity data model using database
first approach He is confused about which EDM layer stores the information like
tables views and stored procedures. help john in identifying the suitable layer?
—-> Storage Layer.

Jhon wants to know which Model generation approach in entity framework he can
use so that he wants to create Model classes based on the designer tool and then
based on this the database will be created? —–> model first.

Which of the following LINQ syntax can be used to retrieve the contents of an
integer array called “numbers” in descending order —-> D.from i in numbers
orderby numbers descending \OR A.from i in numbers orderby i descending select i.

How many primary keys can be there for a table? –>One.

Which of the following Linq Api is used to connect and work with collections
the arraylist etc. —>Linq to objects.

Identity which of the following variables are global variables in SQL server.
—-> (A,B)@@identity,@@Error.

Consider a table employee with empname as one of its column and you want to
fetch as employees whose empname starts with ‘a’ and ends with ‘e’ character.
—–> a%e.
Select EmpName from Employee Where EmpName Like ‘a%e’

using System;
using System.linq;
class SimplestLambda{
static void main(){
int[] scores={9,7,82,85,95,2};
int highScoreCount =scores.Where(number =>number<80.Count(); Console.Writeline(highScoreCount); } } ———————————-> 3

using System;
using System.Linq;
class LINQ1{
static void main(String[] args){
int[] array1={8,4,7,3,6,1};
var result= from number in array1 where (number % 2)==0
orderby number descending
select number;
foreach (int value in result)
{
Console.Write(value+” “);
}
}
} ——————————————————-> 8 6 4.

create table Customer
(custId int primary key, custName varchar(50) not null,
city varchar(50) check (city in (‘Bangalore’,
‘pune’,’Hyderabad’)))
statement 1:
insert into Customer values(1,null,’pune,)
statement 2:
insert into Customer values(2,’Mark’,’Chennai’);
————————>Both statement fails and no records gets added.

which of the following command in SQL server makes the updates performed by the
explict transaction permanent in the database —–> COMMIT.

peter is a novice developer who wants to perform the operation on set of
records from database in a read only and forward only mode.He wants to know which
method of sqlcommand to be executed to achieve the same ——> ExecuteReader.

Public int GetEmpCount(){
connEmp.Open();
cmdEmp=new SqlCommand(“select count(*) from employees”, connEmp);
connEmp.Close();
return count;
}
—————————>int count=Convert.ToInt32(cmdEmp.ExecuteScalar());// ExecuteReader()
27.public class EMployee{
public int EMPId {get;set;}
public string EmpName{get;set;}
public double Salary{get;set}
public Dept Dept{get;set;}
} —————————> Dept.(navigation property)

How will a developer specify that a stored procedure is being called from
ADO.NET? —->Setting the CommandType property of the sqlCommand object to
storedProcedure.

What will be the data type of the result variable shown in the following code
snippet?
var result= from e in employees select e;
————————————–>IEnumerable

using System;
using System.Linq;
class LINQEx
{
static void Main(String[] args){
String[] accenture={“HDC”,”BDC”,”CDC”,..}
};
var result =accenture.Select(location =>location).Count();
/**Missing Code to print */
}
}
——>Console.WriteLine(result);

Consider a data context class called EMployeeContext with a property called
Employees of type DbSet
which of the following queries can be used to delete the details of an employee
based on the employeeId 101? the Employee Id is the primary key in the database.
—->EmployeeContext context=new EmployeeContext();
var employee=context.Employees.Remove(context.Employees.Find(101));
OR
EmployeeContext context=new EmployeeContext();
var employee=context.Employees.Find(101);
Contex.Employees.Remove(Emp);

Jhon wants to know which model generation approach in entity framework he can
use so that he wants to create the tables in database and then create EDM based on
the tables? —–>Database first.

Which of the following command needs to be changed in ADO.Net to specify that
we are using with stored procedure?
—>cmdEmp.CommandType=CommandType.StoredProcedure.

int a = 20;
a++;
a += –a;
console.WriteLine(“value of a {0}”,a);
a. value 41
b. value 40
c. value 39
d. value 42
ans :41

  1. strong name assembly can refer only strong name assembly (T/F)
    True.
    Read this notes
    A strong name consists of the assembly’s identity—its simple text name, version number, and culture information (if
    provided)—plus a public key and a digital signature. It is generated from an assembly file (the file that contains the
    assembly manifest, which in turn contains the names and hashes of all the files that make up the assembly), using the
    corresponding private key. Microsoft® Visual Studio® .NET and other development tools provided in the Windows
    Software Development Kit (SDK) can assign strong names to an assembly. Assemblies with the same strong name are
    expected to be identical.
    You can ensure that a name is globally unique by signing an assembly with a strong name. In particular, strong names
    satisfy the following requirements:

Strong names guarantee name uniqueness by relying on unique key pairs. No one can generate the same
assembly name that you can, because an assembly generated with one private key has a different name than an
assembly generated with another private key.

Strong names protect the version lineage of an assembly. A strong name can ensure that no one can produce a
subsequent version of your assembly. Users can be sure that a version of the assembly they are loading comes
from the same publisher that created the version the application was built with.

Strong names provide a strong integrity check. Passing the .NET Framework security checks guarantees that the
contents of the assembly have not been changed since it was built. Note, however, that strong names in and of
themselves do not imply a level of trust like that provided, for example, by a digital signature and supporting
certificate.

When you reference a strong-named assembly, you expect to get certain benefits, such as versioning and naming
protection. If the strong-named assembly then references an assembly with a simple name, which does not have these
benefits, you lose the benefits you would derive from using a strong-named assembly and revert to DLL conflicts.

Therefore, strong-named assemblies can only reference
other strong-named assemblies

3. Default scope of the class is public (T/F)
False.

  1. what is the default access level of the class?
    Private
  2. which of the following is not used to create the .net domain
    a. ASP.NET
    b. IIS
    c. Internet Explorer
    d. Windows Shell
    DataBase/Brijesh: ASP.Net
    Mam:Windows Shell
    Domain is created for Web Application. For creating domain ASP.Net, IIS and IE is required.
  3. Which keyword denotes the reference to an object of current class
    a.this()
    b. inIt
    c.out
    d.none of these
    this
  4. All .net code have to be CLS complaint (T/F)
    Brijesh-True

8 In which namespace are all collection class located ?

a.system.configuration
b.system.collection.
c.system.codeDom
d.system.componentmodel
b

  1. What is true about destuctors ?
    a. destuctor cannot be used with structs
    b. you cannot pass arguments to destuctors c. destuctor doesn’t have the same name of the class
    d. destructor can be overloaded
    Ans : B
  2. all elements of an interface
    Ans : public
  3. Constructor for the class Helloworld
    Ans : public Helloworld();
    12.multiple interfaces can be inherited (T/F) Ans :T
    13.Base class for all arithamatic operation
    Ans: System.ArithamaticException
  4. The entity with some characteristics and behaviour
    Ans: object
    15.—————-is the execution engine for .net
    Ans: CLR
  5. which one is true about Visual source safe question..
    a.undo check out rollback
    b.we can access vss directly through vb.net 2005
    c.one more point
    d. all the above
    Ans : All the above
  6. Relation between parent and child.. (inheritance..)
    Note : the question from knowledge check
    a. parent object cannot be assigned to a child object directly without casting ( child c! = new
    parent();
    b. assigning child instance tto parent obj = (parent p = new child)
    c. casting a child obj to child obj and assigning it to parent obj(parent p = (child)childobject;)
    d. casting a parent object to a child object and assigining it to a child object will not throw any
    errors
    (child c = (child)parent object);
    e. all the above
    Ans : All the above
  7. which operator is used to implement interface Ans : operator
    19which modifier can be used in which the access is limited to that class and thetypes of its sub class
    Ans : protected
    20.static method cannot be virtual (T/F)
    True
  8. Type of abstraction
    a. data abstraction
    b. class abstraction
    c. both option a and option b
    Abstraction is 3 types : Data Abstraction, Functional Abstraction and Object Abstraction
  9. class Test
    {
    string s = “Test”;
    string t = string.copy(s);
    Console.writeline ( s== t)
    Console.writeline ((object)s == (object)t); }}
    a.True True
    b.True False
    c.False False
    d.False True
    b – True False
  10. Keyword thatis used to inform the compiler that a variable is initialized with in a method
    a. this
    b. out
    c. Init only
    d. None of these
    Out
  11. using system
    class A
    {
    Public static int X = B.Y +1;
    } Class B
    {
    Public static int Y = A.X+1;
    Static void Main()
    {
    Console.writeline (“x = {0}, y = {1} “,A.X,B.Y);
    }
    }
    a.
    b.
    c.
    d.
    e.
    f.

X =1 Y= 1
X = 2 Y =1
X=0 Y=0
Will not execute becose circular ref in static field initialize
X = 1, Y = 2
Ans is X = 1, Y = 2

  1. class Test
    {
    Int I;
    Bool t is false
    If ( I == 0)
    {
    Console.writeline (“true…”);
    }
    Else
    {
    Console.writeline (“false..”)
    }
    It will give error as I is not initialized.

26.which of the following is true about this operator
Ans: the this member can never be declared it is automatically implied when you create a
class
27.which of the following accept input from the user
Ans: console.readline();
28.which one of the following code samples write out “C:\WINNT\System32” to the console.
Ans : “C:\WINNT\System32”

29.what is the purpose of sealed class
Ans : it prevent inheritance
30.which of the following variable share a single copy of the object
Ans :static
31.a question about oopss
Ans : one option contains polymorphism,encapsulation,inheritance
Another option stared with object
These two are the answer for this question
32.which of the statements is/are false (choose the best option)
a. private methods are inherited in derived class
b. interface methods can be declared as virtual
c. static methods cannot be virtual
d. the signature of the override method must remain same
B and A if they have given Private methods are inherited in derived class.

serive that allow code to work functions and structures that has been exported WIN32.dll
a.delegate
b.platform invocation
c.COM interoperability
Ans :platform invocation
Did Not understand this question
34.A question from Tag Navigator
All options contains info about sourse window and code window
Ans : All the Above..
35.A try block must contain Finally (T/F)
Ans : False
36.A question from method overloading
Options contains argument,signature,access specifier.
All these options are bulleted in the text book
Ans : All the above
37.one program which contains
S=3;
console.writeline (s+85.ToString())
Ans : 385
38.Keyword that is used to inform the compiler that a variable is initialized in a method
Ans : out

What are the workflow authoring styles supported by WWF
Choose two most appropriate option
a) Base class library
b) Entity Style
c) Random Style
d) Data-driven style
Answer: a,d

  1. Identify the option which follows the correct order of Action
  2. Obtain the Data source.
  3. Execute the query.
  4. Create the query
    Choose most appropriate option
    a) 1,2,3
    b) 3,2,1
    c) 1,3,2
    d) 3,1,2
    Answer: c
  5. _ is a process in which a Web application accepts data from a user and processes it
    Choose most appropriate option.
    a) Page Init
    b) Page Load
    c) ASP.NET
    d) Page Posting
    Answer: d
  6. The class that encapsulates the event information should be derived from __
    Fill in the blank with an appropriate option
    a) System.EventArgs
    b) System.EventHandler
    c) System.Delegate
    d) System.componentModel.EventDescriptor
    Answer: a
  7. What are the different components of LINQ?
    Choose four appropriate options.
    a) LINQ to Objects
    b) LINQ to XML
    c) LINQ to SQL
    d) LINQ to DataSet
    e) LINQ to Datatable
    f) LINQ to DataRow
    Answer: a b c d
  8. The specific protocols and serialization formats that are used to support successful
    communication with the service
    Choose most appropriate option
    a) Operation Contract
    b) Service Contract
    c) Fault Contract d) Data Contract
    e) All of the above
    f) None of the above
    Answer: b
  9. Consider the enumeration below enum ThreadPriority { Lowest, BelowNormal, Normal,
    AboveNormal, Highest }
    Choose two appropriate options
    a) Threadpriority becomes important only when multiple threads are simultaneously active
    b) Lowest and Highest are not part of this enumeration
    c) A thread’s Priority property determines how much execution time it gets relative to other
    active threads in the operating system
    Answer: a c
  10. In Memory mapping, which class signifies a randomly accessed view of a memory-mapped file
    Choose most appropriate option
    a) MemoryMappedViewStream
    b) MemoryMappedViewAccesser
    c) CreateViewAccessor
    d) MemoryMappedFileView
    e) None of the above
    Answer: b
  11. In WPF, which layout control aligns the child controls to the edges of panel
    Choose most appropriate option
    a) StackPanel
    b) DockPanel
    c) GridPanel
    d) CanvasPanel
    e) None of the above
    Answer: b
  12. A _ expression is an anonymous function that can contain expressions and statements and
    can also be used to create delegates or expression tree types
    Choose the appropriate option
    a) Join
    b) XML
    c) Data
    d) lambda
    e) SQL
    Answer: d
  13. Which of the below are invalid serialization attributes ?
    Choose two most appropriate options.
    a) XMlRootElement
    b) XmlAttribute
    c) XmlElement
    d) XmlElementName
    Answer: a d
  14. __ provides a means of reading a forward-only stream of rows from a SQL server database.
    Fill in the blank with an appropriate option
    a) SqlDataReader b) Dataset
    c) DataTable
    d) Dataview
    Answer: a
  15. During a Jagged Array practice session, Shruthi wrote following code:
    int[][] myarray- new int[][3];
    myarray [0]=new int[3];
    myarray [1]=new int[4];
    myarray [2]=new int[5];
    IDE continued to show an error for this Jagged Array construction According to you which line
    is causing this error?
    Choose most appropriate option
    a) int[][]myarray new int[][3];
    b) myarray [0]=new int[3];
    c) myarray [1]=new int[4];
    d) myarray [2]=new int[5];
    Answer: a
  16. Consider the following code and identify the attribute to be added to make the Name a
    property of Employee type in the data contract
    [DataContract]
    Public class Employee
    {
    private string m_Name;
    public string Name { get { return m_Name;} set { m_Name = value; } }
    }
    Choose most appropriate option
    a) [DataMember]
    b) [DataService]
    c) [DataAttribute]
    d) [DataProperty]
    Answer: a
  17. Please select the two correct statements for XML document:
    Choose two appropriate options
    a) XSD is the XML-based alternative of DTDs having the same purpose of DTDs but more
    powerful and extensible
    b) DTD is the XML-based alternative of XMLs having the same purpose of XMLs but more
    powerful and extensible.
    c) DTD is the older standard. It is most probable that XSD will replace DTD for validating XML
    Documents.
    d) XSD is the older standard. It is most probable that DTD will replace XSD for validating XML
    Documents.
    Answer: a c
  18. Rahul is trying to use StringBuilder class in a program, but he is getting error. To use the
    StringBuilder class which namespace he should include in the program
    Choose most appropriate option
    a) System.String
    b) System.Globalization c) System.io
    d) System.Builder
    e) None of the above
    Answer: e
  19. please select the correct task to prevent possible code injections
    choose three appropriate options
    a) Client side validation need to be done by Java Script
    b) Don’t store sensible data into cookies
    c) Don’t use hidden boxes to hold data
    d) Don’t depend on client side javascript validation
    Answer: b c d
  20. Which of the following statement(s) is/are true about the operator overloading?
    Choose most appropriate option
    a) Binary operators can be overloaded
    b) The cast operator cannot be overloaded, but you can define new conversion operators
    c) Unary operators can be overloaded.
    d) All of the above
    Answer: d
  21. The goal of ____is to decrease the amount of code and maintenance required for data-oriented
    applications
    Choose the appropriate option
    a) LINQ to C#
    b) LINQ to Entities
    c) LINQ to Database
    d) LINQ to XML
    Answer: b
  22. In the .NET Framework, where is the version information of an assembly stored?
    Choose most appropriate option
    a) Manifest
    b) Visual Source Safe
    c) Common type System
    d) Version Control
    Answer: a
  23. Identify drawbacks of the Design Patterns from the below mentioned options
    Choose two appropriate answers
    a) Patterns do not lead to direct code reuse
    b) Patterns are deceptively simple
    c) Teams may not Suffer from pattern overload
    d) Maintainability and reusability
    Answer: a b
  24. This event is raised by the page object. This event is used to complete all tasks that require
    initialization
    Choose the appropriate option
    a) Prelnit
    b) Preload
    c) Init
    d) Initcomplete e) LoadComplete
    Answer: d
  25. A class source-code file that is compiled at run time. These classes can be: HTTP Module,
    HTTP Handler. Can also be a code-behind file for an ASP.NET page or a stand-alone class file
    containing application logic- find the extension of these files above
    Choose most appropriate option
    a) .config
    b) .cs, .jsl, .vb
    c) .licx, .webinfo
    d) .resources, .resx
    Answer: b
  26. which of the following does an assembly contain ?
    Choose most appropriate option
    a) Manifest type metadata, Resources, MSILcode
    b) Manifest, type metadata
    c) Manifest, type metadata, resources
    d) Manifest
    Answer: a
  27. Which Method is used to create a MemoryMappedViewAccessor that maps to a view of the
    memory-mapped file
    Choose most appropriate option
    a) MemoryMappedViewAccesser()
    b) MemoryMappedViewStream()
    c) CreateViewAccessor()
    d) CreateMemoryMappedViewAccessor()
    Answer: c
  28. Which of these namespaces handle the following information Language-Country/ Region Calendars in use Format pattern for dates -Currency
    Choose most appropriate option.
    a) System.String
    b) System.Globalization
    c) System.lO
    d) System.Reflection
    Answer: b
  29. WPF Which control n the WPF application has a property GroupName ?
    Choose most appropriate option
    a) CheckBox
    b) RadioButton
    c) ComboBox
    d) All of the above
    Answer: b
  30. In an interview Akshay was asked to evaluate following code and determine the Output.
    class Program
    {
    static Program()
    { int number= 100; int denominator= intParse(“0”);
    int result = number /denominator; Console writeLine(result); } }
    class MyClass { static void Main() { Program program= new Program(); } }
    According to you, what should be the output of this code? Choose most appropriate option
    a) System.DivideByZeroException
    b) System.TypelnitializationException
    c) System.InvalidCastException
    d) There won’t be any exception, result would get printed.
    Answer: b
  31. Shruthi is working as a developer. She has to write the code to Create a ConnectionString.
    Which of the following parameter of ConnectionString she should use to specify the name of the
    database ?
    Choose two appropriate options.
    a) Provider
    b) Initial Catalog
    c) Database
    d) Data Source
    Answer: b c
  32. Which of the following is/are Statement(s) related to interface ?
    Choose most appropriate option
    a) Interface is a type whose members are all public and abstract by default
    b) Interface itself can inherit other interfaces
    c) To implement an interface, class uses the same syntax that is used for inheritance.
    d) All the above
    Answer: d
  33. True/False: XML serializes only the public properties and private fields of an object.
    Choose most appropriate option
    a) TRUE
    b) FALSE
    Answer: b
  34. Refer to the below code and Identify the missing statements.
    [ServiceContract]
    Public interface IHello
    {
    void SayHello(string name);
    }
    Choose most appropriate option.
    a) [OperationContract] attribute needs to be included about the SayHello method.
    b) [DataMember] attribute needs to be included about the SayHello method.
    c) [ServideContract] attribute needs to be included about the SayHello method.
    d) None of the above.
    Answer: a
  35. To execute the below code successfully, which namespace to be included
    Using System; class MyClass { static void Main(String[] args) { Parallel.For{21, 31, i =>
    {Console.WriteLine(i);}};} }
    choose most appropriate option
    a) System.Threading
    b) System.Threading.Tasks
    c) System.Linq
    d) Using System.Collections.Concurrent
    Answer: b
  36. Consider the following code and identiry the statements which are true?
    using System;
    using System.Linq;
    class OrderDemo {Static void Main(){String[] englishletters={“d”, “c”, “a”, “b”};
    var sorted = from englishletter in englishletters orderby englishletter select englishletter;
    foreach(string value in sorted) { Console.WriteLine(value);}}}
    Choose two appropriate options.
    a) Englishletters is an unsorted array
    b) Sorted is an IEnumerable
    c) The output will be in the descending order
    d) The foreach loop is responsible for sorting the englishletters
    Answer: a,b
  37. Which of the following substantiates the use of stored procedure?
    Choose most appropriate option.
    a) The number of requests between the server and the client is reduced.
    b) The execution plain is stored in the cache after It is executed the first time
    c) .Stored procedures accept parameters.
    d) You can bypass permission checking on stored procedure.
    Answer: b
  38. _______ is the process of converting the state od an object into a form that can
    be persisted or transported.
    Fill in the blank with an appropriate option.
    a) Delegate
    b) Serialization
    c) Events
    d) Object Initalizer
    Answer: b
  39. Samriti needs to create a UML Diagram that can depict the user requirements scenarios in
    which your system or application interacts with people, organizations or external systems.
    Which diagram should she be using?
    Choose most appropriate option
    a) Use Case Diagram
    b) Class Diagram
    c) Object Diagram d) Sequence Diagram
    Answer: a
  40. Rohit wanted to print the SQL server name of his system. Which code should use in SQL
    server name?
    Choose two most appropriate options.
    a) Select @@servername
    b) print@@servername
    c) select@@server
    d) print@@server
    Answer: a,b
  41. In WWF, __ is the interaction between the Host processes and a specific activity
    in an specific workflow instance.
    Choose most appropriate option.
    a) Local Communication
    b) Compensation
    c) Correlation
    d) Serialization
    Answer: c
  42. How the rules or conditions expressed in WWF to implement business logic
    Choose most appropriate option
    a) Conditions can be articulated as declarative, or defined in code
    b) Rules consist a condition statement and collections of actions that are not performed based on
    the result of the condition
    c) Rules are expressed as an XML file
    d) a & c
    e) a & b & c
    Answer: d
  43. Which of the following will legally declare a construct and initialize an array?
    Choose most appropriate option.
    a) char myArray[] = {‘a’, ‘b’, ‘c’};
    b) char myArray[] = {a ; b; c; );
    c) char myArray[] = {‘a’; ‘b’; ‘c’);
    d) char [ ] myArray= {‘a’, ‘b’, ‘c’};
    Answer: d
  44. Web Server provides a detailed description of the extensions, filters, and script mapping
    Choose the appropriate option
    a) Internet Server Active Programming Interface (ISAPI}
    b) Internet Served Application Programming Integration (ISAPI)
    c) Internet Server Application Programming Interoperability (ISAPI)
    d) Internet Server Application Programming Interface (ISAPI) Answer: d
  45. A jagged array is an array of arrays, and therefore its elements are __.
    Fill in the blank with an appropriate option.
    a) Value types
    b) Reference types
    c) Both Value types and Reference types
    Answer: b
  46. Which of the following is true about ADO.NET?
    Choose most appropriate option.
    a) ADO.NET is an object oriented set of libraries that allows you to interact with data sources.
    b) ADO.NET classes are found in System.Data.dll.
    c) ADO.NET classes are integrated with XML classes.
    d) ADO.NET contains .NET Framework data provieder for connecting to a database.
    e) All of the above.
    Answer: e
  47. Identify the statements which are in Camel Case.
    Choose the two appropriate options.
    a) Public void Show(string bookName){…}
    b) totalAmount
    c) BlueColor
    d) Public event EventHandler ClickEvent
    Answer: a,b
  48. Which of the following are facts about Non-persistence memory mapped files?
    Choose most appropriate option
    a) These files are memory-mapped files that are associated with a source file on a disk.
    b) When the last process has finished working with the file, the data is saved to the source file on
    the disk.
    c) These memory-mapped files are suitable for working with extremely large source files.
    d) These files are suitable for creating shared memory for inter-process communications
    Answer: d
  49. LINQ relied on the concepts of extension of extension methods, anonymous types,
    anonymous methods and _____.
    Fill in the blank with an appropriate option.
    a) Lambda expressions
    b) Xml expressions
    c) Data expressions
    d) Sql expressions
    Answer: a
  50. What are the services will be provided by Windows Workflow – Foundation?
    Choose two most appropriate option
    a) Transaction Services b) Migration Services
    c) Scheduling Services
    d) Security services
    Answer: a,c
  51. Are the following statements true or false?
    Statement 1: A Task is a schedulable unit of work. Statement
    2: Task enqueued to a TaskScheduler.
    a) Both statements are true.
    b) Both statements are false.
    c) Statement 1 is false and statement 2 is true.
    d) Statement 2 is false and statement 1 is true.
    Answer: a
  52. Which of the following apply to constructor?
    Choose three appropriate options.
    a) Constructors are methods that set the initial state of an object
    b) Constructors cannot return a value, not even void
    c) Constructors can be inherited
    d) If the class does not explicitly declare a constructor, it will default to a no parameter, do
    nothing constructor
    Answer: a, b, d
  53. What will be the output of the below program using System;
    using System.IO;
    class Program
    { Static void Main(string[] args)
    { StreamWriter sw = File.CreateText(“C:\accenture.txt”);
    try { sw.WriteLine({“Welcome to Accenture”);}
    catch(IOException e){ Console.WriteLine(e.Message);}
    finally{ if(sw != null) sw.Close();}}}
    Choose most appropriate option
    a) Accenture.txt file is created in C: drive
    b) IOException will be thrown
    c) Unhandled Exception
    d) Compiletime Error
    Answer: a
  54. Shruthi is working on the code below. When she executes this code she is facing this error –
    using directive error.
    Which of the option will resolve this error?
    Int[] numbers = new int[7] (0,1,2,3,4,5,6};
    var numQuery = from num in numbers where (num % 2 ) == 0 select num;
    foreach (int num in numQuery) {Console.Write(“{0}”, num);}
    Choose most appropriate option
    a) She must use the System.Linq namespace b) She must use the System.Linq.Expressions namespace
    c) She must revise her LInq query
    d) None of the above
    Answer: a
  55. With respect to generic concept, developers can create which generic item?
    Choose three appropriate options.
    a) Generic constant
    b) Generic class
    c) Generic event
    d) Generic delegate
    Answer: b,c,d
  56. Radha wants to sort data stored in an array. She doesn’t want to work on the sorting
    functionality. Do we have any provision in the .NET framework FCL to help her in sorting?
    Choose most appropriate option
    a) Yes, she can use System.Sory(array)
    b) Yes, she can use System.Data.Sort(array)
    c) Yes, she can use System.Array.Sort(array)
    d) No, she need to write the sort functionality
    Answer: c
  57. Error handling in WCF service is handled by ___.
    Choose most appropriate option.
    a) Fault Contract
    b) ServiceContract
    c) DataContract
    d) MessageContract
    Answer: a
  58. Which of the options is valid with respect to below statements
    Statement1: StringBuilder saves time and memory by not creating a new string each time an
    operation is performed on a string.
    Statement2: System.Math class provides constants and static methods for trigonometric,
    logarithmic, and assertion functions.
    Choose most appropriate option.
    a) Statement1 is True. Statement2 is false
    b) Statement1 is False. Statemetn2 is True
    c) Statement1 is False. Statement2 is False
    d) Statement1 is True. Statement2 is True
    Answer: a
  59. Identify correct syntax for declaring indexer.
    Choose most appropriate option.
    a) public int this[int index] { get{ } set{ } }
    b) public int [int index]this { get{ } set{ } } c) public this[int index] { get{ } set{ } )
    d) public this[int index] int { get{ } set{ } )
    Answer: a
  60. A/An _____ that does not have a WHERE clause produces the Cartesian
    product of the tables involved in the join.
    Choose the appropriate option
    a) Equi Join
    b) Inner Join
    c) Self Join
    d) Cross Join
    Answer: d
  61. Arun wants to retrieve result using a query “select count(*) from employee”. Which is most
    appropriate SqlCommand method for his requirement
    Choose most appropriate option
    a) Execute Reader
    b) ExecuteQuery
    c) ExecuteNonQuery
    d) ExecuteScalar
    Answer: d
  62. CREATE VIEW [dbo].[viewmyTable] AS SELECT D.DeptName, D.Location, E.Name FROM
    Department D LEFT OUTER JOIN Employee E ON D.DeptID = E.DeptID GO
    Predict the output, when the above query executed?
    Choose most appropriate option
    a) Commands execute successfully
    b) Incomplete query
    c) Syntax error
    Answer: a
  63. Which of the following are True for Workspace
    Choose two appropriate options
    a) Workspace is a folder created within the local system which maps a project in the source
    control.s
    b) Files within the source control which needs changes, should be first loaded into the
    workspace of the local system. Any changes made to the files are stored in the local workspace.
    c) Only one workspace can be maintained for a single project in the source control.
    d) Files need to be checked-out in order to upload changes into source control.
    Answer: a,b
  64. Visibility qualifier is used for which off the following?
    Choose most appropriate option.
    a) Specifying different visibility for the get and set accessors of a property or an indexer.
    b) Setting the visibility off the accessor get and set to public even though the property visibility
    is set to protected. c) Setting the visibility of the accessor and set to public even though the property visibility is set
    to internal.
    d) All off the above.
    Answer:a
    63.Select the two correct two statements for xml schema(XSD)
    Choose most appropriate option.
    a) The elements is the root element for XSD.
    b) Has data types and namespaces,like DTDs.
    c) Elements in schemas are divided into three types: Simple Elements Mixed Elements Complex
    Elements.
    d) XSD is written similarly to xml as xsd makes use of xml syntax, hence most of the rules to xml
    apply to xsd.
    Answer:a,d
  65. State true or false for the statements for design patterns.
    Statement 1: Prototype-A fully initialized instance to be copied or cloned.
    Statement 2: Singleton-A class of which only a multiple instances can exist.
    Choose most appropriate option.
    a) All the statements are true.
    b) All the statements are false.
    c) Statement1 is true and statement2 is false.
    d) Statement2 is true and statement1 is false.
    Answer: c
    65.What is the .NET Collection class that allows an element to be accessed using a unique key?
    Choose most appropriate option.
    a) Arraylist
    b) StringCollection
    c) Stack
    d) Hashtable
    Answer: d
  66. Rajesh needs to copy only specific range of elements from MyArray to copyMyArray. He is
    using Follwing code.
    Int[] myarray= new int[3] {20,19,21};
    Int[] copyarray= new int[3];
    Array.Copy(myarray,copyarray,1);
    Would this code give him desirable Output?
    Choose most appropriate option.
    a)Yes
    b)No
    Answer:a
  67. Consider the following statements and identify the WCF program 1,These are programs that
    consume the services 2.They are normally the ones the initiate the messaging to the service.
    Choose most appropriate option.
    a) Message
    b) Client c) Intermediates
    d) None of the option
    Answer:b
    68.Which of the bbelow syntax is correct to define operator method or to perform operator
    overloading?
    Choose most appropriate option.
    a) Public static op(arglist) {}
    b) Public static returnvalue op(arglist){}
    c) Public static returnvalue operator op(arglist){}
    d) All of the above
    Answer:c
  68. Identify two conditions from the following that need to be met for multicast delegates.
    Choose most appropriate option.
    a)None off the parameters of the delegate is an output parameter.
    b)The return type of the delegate is void.
    c)The parameter o the delegate is an output parameter
    Answer:a,b
  69. What is /are the different component(s) off LINQ?
    Choose most appropriate option.
    a) LINQ to Objects
    b) LINQ to XML
    c) LINQ to SQL
    d) LINQ to Entity
    e) All of the above
    Answer: e
    71.Identify the description of @@IDENTITY.
    Choose most appropriate option.
    a) Returns the error number for the last Transact-SQL statement executed.
    b) Returns the last –inserted identity value.
    c)Returns the number of rows affected by the last Statement.
    Answer:b
    72.Identify the list off Common Exception Classes
    Choose most appropriate option.
    a) System.StackException
    b) Syystem.NullReferenceException
    c) System.ArrayTypeMismatchException
    d) System.TypeMisMatchException
    e) System.InvvalidCastException
    Answer:b,c,e
  70. Read the statement below and identify the workflow component This is the act of undoing
    any actions that were performed by a successfully completed activity because of an exception
    that occurred elsewhere in a workflow
    Choose most appropriate option.
    a) Activity
    b) Compensation
    c) Service d) Workflow persistence
    Answer:b
  71. John is developing an application for ABC company in which he wants to combine
    application UIs,2D graphics,3D graphics, documents and multimedia is one single framework.
    Which component can he use?
    Choose most appropriate option.
    a)WPF
    b)WCF
    c)Linq
    d)OOPS
    Answer: a
    75.What is/are the advantages of LINQ over stored procedures?
    Choose most appropriate option.
    a)Debugging- it is really very hard to debug the stored procedure but as LINQ is part off .NET,
    you can use visual studio’s debugger to debug the queries.
    b)Deployment- With stored procedures, we need to provide an additional script for stored
    procedures but with LINQ everything gets compiled into single DLL hence deployment
    becames easy.
    c)Type Safety- LINQ is type safe, so queries errors are type checked at compile time.it is really
    good to encounter an error when compiling rather than runtime exception
    d)All off the above
    Answer: d
  72. which of the below are valid Statements about DataReader and Data set
    Choose most appropriate option.
    a) DataReader reads all the the records at a time and it is used in multiple databbbases.
    b) DataSet always reads one record at a time and it moves into a forword direction.
    c) DataReader is a connected Architecture
    d) Dataset is a collection of in memory tables
    Answer:c,d
  73. Identiffy the functions of common type System(CTS)
    Choose most appropriate option.
    a) They form the fundamental unit off deployment, version control, reuse, activation scoping, and
    security permissions
    b) Most off the members defined by types in the .NET framework class Library are CLS-compliant
    c) Establishes a framework that helps enable cross-Language integration, type safety, and high
    performance code execution
    d) Provides an object –oriented model that supports the complete of many programming
    languages
    Answer:c,d
  74. Identify the tasks a user is able to perform in Source Control Explorer
    Choose most appropriate option.
    a) Create/Rename/Delete files and folders
    b) Check in/out files
    c) Get latest/Specific version
    d) All of the above Answer:d
    79.__ Represents the standard input, output, and error streams ffor console
    applications. This class cannot be inherited.
    Fill the blank with appropriate option.
    a) Console class
    b) TextWriter class
    c) Text class
    Answer:a
    80.What is the namespace for “Task” class?
    Choose most appropriate option.
    a) System.Tasks
    b) System.Threading.Tasks
    C) System.Diagnostiscs.Tasks
    d) System.Dynamic.Task
    Answer:b
    81.State true or false for the below statements.
    Statement1 : Multicast delegates are used extensively in event handling.
    Statement2 : Delegation can be used to define callback methods
    Choose most appropriate option.
    a) Statement1 and Statement2 are true
    b) Statement2 is true and Statement2 is false
    c) Statement1 is true and Statement2 is false
    d) Statement2 and Statement1 are False
    Answer:a
    82.________________namespace provides classes for using a memory mapped ile,which maps
    the contents of a file to an applications logical address space.
    Fill with the most appropriate option.
    a)System.MemoryMappedFile
    b)System.MemoryMappedFiles
    c)System.IO.MemoryMappedFiles
    d)System.IO.Memory
    Answer:c
    83.Identify the WCF contract considering the following statement
  75. WCF contracts defines implicit contracts for built in data types like string and int.
  76. This contract defines which data types are passed to and from the service
    Choose most appropriate option.
    a) Service Contract
    b) Fault contact
    C) Data Contract
    d) Message contact
    Answer:c
  77. Which of the below statements are correct about Indexers
    Choose most appropriate option.
    a) Indexers are location indicators
    b) Indexers are used to access class objects
    c) Indexer is a form of property and works in same way as a property
    d) a&b e) b&c
    f) a,b&c
    Answer:f
    85._________and __________ methods of a delegate helps to process delegate
    asynchronously
    Fill the blank with appropriate option.
    a) BeginInvoke(),EndInvoke()
    b) InvokeBegin(),InvokeEnd()
    c) Begin(),End9)
    d) BeginInvokeDelegate(),EndInvokeDelegate()
    Answer:a
    86.Which option gets the version of the selected file/folder specific to date, changeset, label,or
    workspace version?
    Choose most appropriate option.
    a)GetSpecificFile
    b)GetLatestVersion
    c)GetSelectVersion
    d)GetSpecificVersion
    Answer:d
    87.All query operations of LINQ consist of three district actions
    Choose most appropriate option.
    a) 1. Obtain the data source 2. Declare the Data source 3.Excute the data source
    b) 1. Declare the data source 2.Initialize the query 3. Execute the query
    c) 1. Declare the Data source 2. Create the data source 3 .Execute the Data source
    d) 1. Obtain the data source 2.Create the query 3. Execute the query
    Answer:d
    88.Rajesh is implementing an ASP.NET page. The page include a method named
    GetProjectAllocation that returns dataset. The Dataset includes a datatable named
    ProjectAllocation. Rajesh need to show the data in GridView control named GridView1
    Choose most appropriate option.
    a)Gridview1.DataTable=GetProjectAllocation();
    b)GridView1.DataTable=GetProjectAllocation();GridView1.DataBind();
    c) GridView1.DataSource=GetProjectAllocation();GridView1.DataBind();
    d) GridView1.DataSourceId=GetProjectAllocation();GridView1.DataBind();
    Answer:c
    89._____________is a pre defined, reusable routine that is stored in adatabase
    Fill the blank with most appropriate option.
    a) Function
    b) Stored Proccedure
    c) View
    d) Joins
    Answer:b
    90.Which of the following are True for Workspace
    Choose two appropriate options
    a) Workspace is a folder created within the local system which maps a project in the source
    control.s b) Files within the source control which needs changes, should be first loaded into the
    workspace of the local system. Any changes made to the files are stored in the local workspace.
    c) Only one workspace can be maintained for a single project in the source control.
    d) Files need to be checked-out in order to upload changes into source control.
    Answer: a,b
  78. In LINQ , all the core types are defined in _
    Choose most appropriate option.
    a) System.Linq.XML and System.Linq.Expressions
    b) System.Linq and System.Linq.XML
    c) System.Linq and System.Linq.Expresssions
    d) System.XML.Linq and System.Linq.Expressions
    Answer : C
  79. The _ hosting option is integrated with ASP.NET and uses the features these technologies
    offer, such as process recycling , idle shutdown ,process health monitoring , and message based
    activation.
    Choose most appropriate option
    a) IIS
    b) Windows Services
    c) WAS
    d) Self Hosting
    e) All of the above
    f) None of the above
    Answer : A
  80. What are true about Static Constructors
    Choose two appropriate options
    a) Static variable get instantiated after the static constructor
    b) Static constructors provide the flexibility of statically initializing static variables
    c) Static constructors have access to static members of theirs class only
    d) A static constructors does not have parameters and access modifiers cannot be applied to it
    Answer : C, D
  81. Which of the below statement(s) are valid in Operator Overloading?
    Choose most appropriate option
    a) The conditional logical operators cannot be overloaded
    b) The array indexing operator can be overloaded
    c) The comparison operators cannot be overloaded
    d) All of the above
    e) None of the above
    Answer : A
  82. You want to make a configuration setting change that will affect only the current web
    application. Which file will you change?
    Choose most appropriate option
    a) Web.config b) Machine.config
    c) Global.asax
    Answer : A
  83. Testing which attribute should be used to run code before the first testis run in the class?
    Choose most appropriate option
    a) TestInitialze()
    b) TestClass()
    c) ClassInitialize()
    d) TestStart()
    Answer : C
  84. VSTS is also used for automated unit testing of components and regression testing.
    State TRUE or FALSE
    a) FALSE
    b) TRUE
    Answer : TRUE
  85. Which access modifier cannot be used with data members of a structure?
    Choose most appropriate option
    a) Public
    b) Protected
    c) Internal
    d) Private
    Answer : B
  86. Anand has created a master page named Plant.master. the master page uses the following page
    directives.
    <%@ Master Language=”c#” Src=”~/Plant.master.cs” inherits=”Plant” %>
    He needs to create a content page that uses the master page as a template. In addition , he
    needs to use a single master page for all devices that access the web site. Which code segment
    should be use ?
    Choose most appropriate option
    a) <%@ Page Language=”c#” Theme=”Plant” Skin=”Plant.cs”%>
    b) <%@ Page Language=”c#” MasterPageFile=”~/Plant.master” %>
    c) <%@ Page Language=”c#” device:MasterPageFile=”~/Plant.master” %>
    d) <%@ Page Language=”c#” de:MasterPageFile=”~/Plant.master” %>
    Answer : B
    100.
    CREATE VIEW [dbo].[viewmyTable] AS SELECT D.DeptName , D.Location , E.Name FROM
    Department D JOIN Employee E ON D.DeptID = E.DeptID GO Predict the output , when the
    above view is executed ?
    Choose most appropriate option
    a) A view will be created by selecting deptname , location from the department table and
    employees name from the employee table .
    b) Syntax error c) Incomplete query
    d) A view will be created by selecting deptname , location and name from the department
    table.
    Answer : A
    101.
    Are the methods below a valid overload
    Public int Sum(ref int a , ref int b)
    Public int Sum(out int a , out int b)
    Choose most appropriate option
    a) Yes
    b) No
    Answer : No
    102.
    State true or false for the below statements.
    Statements1. Extension Methods: Which gives us the capabilities to asses our own custom
    methods to data types without deriving from the base class.
    Statement2. Object Initializer: allows you to pass in named values for each of the public
    properties that will be used to initialize the object.
    Choose most appropriate option
    a) Statement 1 and statement 2 are true.
    b) Statement 1 and statement 2 are false.
    c) Statement 1 is false and statement 2 is true.
    d) Statement 2 is false and statement 1 is true.
    Answer : A
    103.
    True/False : Fault Handling is a method of the workflow runtime engine that
    synchronously handles the exceptions that occur in the activities
    Choose most appropriate option
    a) TRUE
    b) FALSE
    Answer : FALSE
    104.
    Which of the following are true about Delegates?
    Choose three appropriate options
    a) A delegate can reference a method only if the signature of the method exactly matches the
    signature specified by the delegate type
    b) A delegate allows the programmer to encapsulate a reference to a method insidea delegate
    object
    c) Delegate are similar to function pointers
    d) Generally useful way for objects to signal state changes that may be useful to clients of that
    object. Answer : A ,B ,C
    105.
    Amulya has created following class:
    Public class Employee { public int EmployeeCode{ get; set;} public string EmployeeName{get;
    set;} public int EmployeeAge{get; set;}}
    Please select correct code for initializing an object by using Object initializers.
    Choose most appropriate option
    a) Employee emp = new Employee(EmployeeCode=111;
    EmployeeName=”Raghav” ;EmployeeAge=26;};
    b) Employee emp = new Employee{EmployeeCode=111,
    EmployeeName=”Raghav”,EmployeeAge=26};
    c) Employee emp = new Employee(){EmployeeCode=111;
    EmployeeName=”Raghav”;EmployeeAge=26;};
    d) Employee emp = new Employee(){EmployeeCode=111,
    EmployeeName=”Raghav”,EmployeeAge=26};
    Answers : B
    106.
    Identify which statements are false about windows Presentation foundation(WPF)
    Choose two appropriate options
    a) Used for standalone and browser hosted applications
    b) Uses XAML markup to implement the appearance of an application
    c) The service-oriented design results in distributed systems that runs between services and
    clients
    d) Provides a programming model for building workflow-based applications in windows
    Answer: C , D
    107.
    How do you specify a constraints for the type to be used in a generic class
    Choose most appropriate option
    a) Class Program where T: MyInterface
    b) Class Program : MyInterface
    c) Class Program constraint T : MyInterface
    d) Class Program where T : MyInterface
    Answer: A
    108.
    VIEW [dbo].[viewmyTable] AS SELECT D.Deptname,D.location ,E.Name FROM
    Department D FULL OUTER JOIN Employee E ON D.DeptID = E.DeptID
    Whats the output , when the above query is executed?
    Choose most appropriate option
    a) Display all the employees with their Departments .Output contains
    b) The employee names and all the department names present in the database
    c) Syntax error
    d) Incomplete Query
    Answer : A
    109.
    Which is the top .NET class from which everything is derived?
    Choose most appropriate option a)
    b)
    c)
    d)

System.Collections
System.Globalization
System.Object
System.IO

Answer : C
110.
From the following option choose the features of WPF
Choose three appropriate options
a) Rich Composition
b) Seperation of appearance and behavior
c) Resolution dependence
d) Highly customizable
Answer : A , B ,D
111.
WCF host can be IIS or WebService or Console Application
Choose most appropriate option
a) TRUE
b) FALSE
Answer : TRUE
112.
Sam is developing an application in which he wants to use child controls are positioned
by rows and columns . which layout he can use ?
Choose most appropriate option
a) Grid
b) Canvas
c) Dock panel
d) Stack panel
Answer : A
113.
Identify the code snippet for creating custom exception class
Choose most appropriate option
a) Class CustomException:ApplicationException{}
b) Class CustomException : AppException{}
c) Class ApplicationException : CustomException{}
d) None of the above
Answer : A
114.
Which of the following is true about overloading?
Choose most appropriate option
a) Overloaded methods must change the argument list.
b) Overloaded methods can change the return type.
c) Overloaded methods can change the access modifier.
d) All of the above.
Answer : D

1)DOT Net collection class allows element to be accessed using a unique key.

Ans:-Hash Table
2)Major use of go keyword.
3)Which of the following represents not equals,

Ans:-<>
4)Significant advantages of rules over check.
5)State true/false: for loops are available for writing SQL server batches.

-False
Foreach is used
6)Which of the foll. is not a JIT compiler

Ans:-Extensive JIT
7)Which of the foll. is used to read & write encoded strings & primitive data types from and to
streams

Ans:-Binary Reader & Binary Writer
8) What are delegate inferences used for? (Select the best option)
a. Used to declare a delegate object
b. Used to wrap a method to a delegate object
c. Used to make a direct assignment of a method name to a delegate variable
without wrapping it first with a delegate object
d. A and C
e. All of the above

9)All elements of an interface should be __ by default.

Ans:-Public
10)State true or false: User defined fns. can return a table.

Ans:-True
For Eg: DataSets are returned.

11)At one time by using ALTER TABLE how many columns are affected

Ans:-1
12)Multiple Methods address can be conctenated to delegate using operator:

Ans:- +
13)Purpose of Assert Methods of N Unit:-

Ans:- To determine correctness of expected results.
14)Class that encapsulates event infmn. should be derived from

Ans:-System .Event.Args
15)In ADO.net to manage data in dissconnected mode

Ans:-SQL Data Adapter
16)Which SQL data types should be used to hold unicode char?

Ans:- I think it is NCHAR-not sure
17)2 fundamental objects in ADO.Net?

ANS:SQLConnection
SQLCommand
18)Preprocessor directive is used to mark the contained block of code is to be treated as single
block & and can be expanded & collapsed

Ans:-# region and #end region
19)Use case Diagrams represents:

Ans:-All of the Above
20) ————- are useful when callback fns. are required.

Ans: Delegates
21)VS.NET defines listbar control in ———————-namespace.

Ans: vbAccelerator.Control.ListBar
22)Question related to NUnit

Ans:-Unit Testing & Regression Testing
23)Questions related to Stored Procedure.

Ans:-Command Type Property
24)Logical group of similar classes related based on functionality is called as _

Ans:- Namespace
25)Which database recovery model has greatest possibility of data loss & is suited mostly for
database that change in frequently.

Ans:-Full Recovery
26)Operator to perform wildcard searches for valid search string value.

Ans:-Like


Leave a Reply

Your email address will not be published. Required fields are marked *