oDesk DotNet 3.5 using C# Test

Programming
Предыдущий Следующий

Вопросы, которые на фриланс сайте oDesk. Тема DotNet 3.5 using C#

На некоторые вопросы правильным является несколько вариантов

By which contract are the ws-addressing action and replyaction elements of the soap envelop controllable when Windows Communication Foundation is used?

  • ServiceContract
  • OperationContract
  • DataContract
  • MessageContract

The output generated by the following code will be:

string t = "This Is a Test";
t.Replace("T", "?");
Console.WriteLine(t);

  • ?his Is a ?est
  • ?his Is a ?es?
  • This Is a Test
  • ?his Is a Test

Which of the following do the advantages of Lambda Expressions over Anonymous methods include?

  • More concise syntax
  • The types for a Lambda Expression may be omitted
  • The body of an anonymous method can not be an expression
  • Lambda Expressions permit deferred type interference, that anonymous methods do not
  • All of the above

Which of the following are true regarding event declaration in the code below?

class Sample
{
event MyEventHandlerType MyEvent;
}

  • MyEventHandlerType must be derived from System.EventHandler or System.EventHandler
  • MyEventHandlerType must take two parameters, the first of the type Object, and the second of a class derived from System.EventArgs
  • MyEventHandlerType may have a non-void return type
  • If MyEventHandlerType is a generic type, event declaration must use a specialization of that type.
  • MyEventHandlerType cannot be declared static

With which class is the task of mapping a specific point in time into units, such as weeks, months, and years accomplished?

  • System.DateTime
  • System.TimeSpan
  • System.Globalization.Calendar
  • System.Globalization.CultureInfo

Which of the following regarding the System.DateTimeOffset structure are true?

  • It provides an exact point in time relative to the UTC time zone
  • It combines a DateTime structure with a TimeZone structure
  • It provides arithmetical operations using values with different offsets from the UTC
  • It can be used to determine the specific TimeZone for a local time

To which of the following do automatic properties refer?

  • You declare (explicitly or implicitly) the accessibility of the property and get and set accessors but do not provide any implementation or backing field
  • You attribute a member field so that the compiler will generate get and set accessors
  • The compiler creates properties for your class based on class level attributes
  • They are properties which are automatically invoked as part of the object construction process

What impact will using implicitly typed local variables as in the following example have?
var sample = "Hello World";

  • The actual type is determined at compilation time, and has no impact on the runtime
  • The actual type is determined at runtime, and late binding takes effect
  • The actual type is based on the native VARIANT concept, and no binding to a specific type takes place
  • "var" itself is a specific type defined by the framework, and no special binding takes place

Which of the following code samples show a valid static constructor?

  • class Sample
    {
       public static Sample()
       {
       }
    }
  • class Sample
    {
       static Sample()
       {
       }
    }
  • class Sample
    {
       static Sample(int value)
       {
       }
    }
  • class Sample
    {
       static void Sample()
       {
       }
    }

For which of the following scenarios does Reflection.Emit provide support?

  • Defining methods dynamically
  • Defining types dynamically
  • Defining assemblies dynamically
  • Defining Instances dynamically
  • Exporting an executable code to a disk based assembly

Which of the following are static methods of the System.Reflection Activator class?

  • CreateComInstanceFrom
  • CreateInstanceFrom
  • GetInstance
  • CreateInstance
  • All of the above

Which of the following does the System.IO.Pipes namespace provide?

  • Interprocess communication through anonymous and/or named pipes
  • Access to named pipes using System.IO.Stream
  • Access to system level pipe security implemented as discretionary access control lists (DACL) and/or system access control lists (SACL)
  • Asynchronous read and write operations
  • All of the above

Which of the following are true about System.Security.Cryptography under version 3.5 of the framework

  • None of the implementations are FIPS-certified
  • Support is provided for the "Suite B" set of cryptographic algorithms as specified by the National Security Agency (NSA)
  • Cryptography Next Generation (CNG) classes are supported on XP and Vista systems
  • The System.Security.Cryptography.AesManaged class allows custom block size, iteration counts and feedback modes to support any the Rijndael based encryption

Which of the following scenarios are applicable to Window Workflow Foundation?

  • Document-centric workflows
  • Human workflows
  • User-interface page flows
  • Builtin support for communications across multiple applications and/or platforms

Which of the following are required to be true by objects which are going to be used as keys in a System.Collections.HashTable?

  • They must handle case-sensitivity identically in both the GetHashCode() and Equals() methods
  • Key objects must be immutable for the duration they are used within a HashTable
  • Get HashCode() must be overridden to provide the same result, given the same parameters, regardless of reference equalityl unless the HashTable constructor is provided with an IEqualityComparer parameter
  • Each Element in a HashTable is stored as a Key/Value pair of the type System.Collections.DictionaryElement
  • All of the above

Which of the following are true about System.GC under version 3.5 of the Framework?

  • You can request that the garbage collector process a generation if it determines that it is appropriate at specific points in your code
  • You can control the intrusiveness of the garbage collector (i.e. how often it performs collections) while your program is running
  • You can control the intrusiveness of the garbage collector (i.e. how often it performs collections) only during application initialization
  • You should specify LowLatency when using Concurrent Server Garbage Collection to improve memory utilization

When using the Demand method of System.Security.IPermission, which of the following will occur?

  • The permissions of the code which invoked the Demand method will be evaluated
  • For permissions which do a stack walk, an exception will occur only if NONE of the calling codes has the required permission
  • For permissions which do a stack walk, an exception will occur if ANY of the calling codes does not have the required permission
  • The permission levels of individual stack frames are always checked regardless of the permission type

Which of the following are true regarding System.Threading.ReaderWriterLockSlim?

  • It is optimized for single processor/core operations
  • It is optimized for usage where writes from multiple sources are common
  • A thread which has a read lock on a resource may not acquire a write lock on the same resource
  • By default, a thread which has a read lock on a resource and attempts to get another read lock on the same resource will throw an exception

When Implementing System.EnterpriseServices.ServicedComponent derived classes, which of the following statements are true?

  • Enabling object pooling requires an attribute on the class and the enabling of pooling in the COM+ catalog
  • Methods can be configured to automatically mark a transaction as complete by the use of attributes
  • You can configure authentication using the AuthenticationOption when the ActivationMode is set to Library
  • You can control the lifecycle policy of an individual instance using the SetLifetimeService method

Which of the following is not an unboxing conversion?

  • void Sample1(object o)
    {
      int i = (int)o;
    }
  • void Sample1(ValueType vt)
    {
       int i = (int)vt;
    }
  • enum E { Hello, World}
    void Sample1(System.Enum et)
    {
       E  e = (E) et;
    }
  • interface I { int Value { get; set; } }
    void Sample1(I vt)
    {
       int i = vt.Value;
    }
  • class C { public int Value { get; set; } }
    void Sample1(C vt)
    {
        int i = vt.Value;
    }

Which of the following is true about C# generics?

  • C# allows non-type template parameters
  • C# supports explicit specialization
  • C# allows the type parameter to be used as the base class for the generic type
  • C# allows a generic type parameter itself to be a generic
  • C# enforces that all codes are valid for all types of parameters

Which of the following are true about Extension methods?

  • They must be declared static
  • They can be declared either static or instance members
  • They must be declared in the same assembly (but may be in different source files)
  • Extension methods can be used to override existing instance methods
  • Extension methods with the same signature for the same class may be declared in multiple namespaces without causing compilation errors

Which of the following is not supported by remoting object types?

  • well-known singleton
  • well-known single call
  • client activated
  • context-agile

While using the capabilities supplied by the System.Messaging classes, which of the following are true?

  • Information must be explicitly converted to/from a byte stream before it uses the MessageQueue class
  • Invoking the MessageQueue.Send member defaults to using the System.Messaging.XmlMessageFormatter to serialize the object
  • Objects must be XMLSerializable in order to be transferred over a MessageQueue instance
  • The first entry in a MessageQueue must be removed from the queue before the next entry can be accessed
  • Entries removed from a MessageQueue within the scope of a transaction, will be pushed back into the front of the queue if the transaction fails

What is the proper declaration of a method which will handle the following event?

Class MyClass
{
public event EventHandler MyEvent;
}

  • public void A_MyEvent(object sender, MyArgs e)
    {
    }
  • public void A_MyEvent(object sender, EventArgs e)
    {
    }
  • public void A_MyEvent(MyArgs e)
    {
    }
  • public void A_MyEvent(MyClass sender,EventArgs e)
    {
    }

Which of the following characteristics do classes in the System.Drawing namespace such as Brush,Font,Pen, and Icon share?

  • They encapsulate native resource and must be properly Disposed to prevent potential exhausting of resources
  • They are all MarshalByRef derived classes, but functionality across AppDomains has specific limitations
  • You can inherit from these classes to provide enhanced or customized functionality
  • They are Value Type objects

Which of the following items are recommended when using XML comments to generate documentation?

  • <exception>
  • <code>
  • <summary>
  • <events>

Which of the following are goals of Windows Communication Foundation?

  • Bringing various existing communication technologies into a unified environment
  • Cross vendor/platform communication
  • Support for asynchronous communications
  • Support for distributed applications based on technologies such as MSMQ and/or COM+
  • All of the above



Вопросы очень плохие и умение программировать они не выявляют, по этому если Вы не можете на них ответить не расстраивайтесь

 

Самостоятельный отпуск Опыт заказа вывоза мусора в Киеве Магія зміни: Від ночі до дня
Магія Вечірнього Неба: Відлякуйте втомленість дня і зануртеся у світ загадок і краси Якби Росія була людиною, то як би її описав психіатр?