• Shuffle
    Toggle On
    Toggle Off
  • Alphabetize
    Toggle On
    Toggle Off
  • Front First
    Toggle On
    Toggle Off
  • Both Sides
    Toggle On
    Toggle Off
  • Read
    Toggle On
    Toggle Off
Reading...
Front

Card Range To Study

through

image

Play button

image

Play button

image

Progress

1/15

Click to flip

Use LEFT and RIGHT arrow keys to navigate between flashcards;

Use UP and DOWN arrow keys to flip the card;

H to show hint;

A reads text to speech;

15 Cards in this Set

  • Front
  • Back
What are the advantages of C# over C, C++ or Java?
*High-level object-oriented programming language.

*More efficient than Java and has useful features such as operator overloading.

*Based on C++ but has several advantages over this older language: it is type-safe, more comprehensively object-oriented, and the syntax has been simplified in several important ways.

*Interoperates exceptionally well with other languages on the .NET platform.
How are namespaces used in C#?
Classes in the .NET framework can be organized using namespaces. The scope of a class is declared using the namespace keyword. You can then include methods from the namespace in your code by including the line “using [namespace];” at the start of your program.
What is a constructor?
The method of a class that is called when an object of that class is created. The constructor initializes class parameters and has the same name as the class.
What is a destructor?
.
Deletes an object of the class from memory. It is called when the object is explicitly deleted by the code you write, or when the object passes out of scope, which can happen when the program exits a function. The destructor has the same name as the class, but with a tilde prefix.
How are methods overloaded in C#?
You can overload methods in C# by specifying different numbers or types of parameters in the method definition. Overloading can help to give your program the flexibility it needs to operate with different types of data input.
What is encapsulation?
Encapsulation – combining function definitions and data together into a class – is used to separate parts of the code from the rest of the program.
Why use encapsulation?
Allows the private data of an object to be hidden from the rest of the program, keep code clean and easy to understand, and allows classes to be reused in other programs.
What is the difference between a class and a struct?
Classes are passed by reference, structs are passed by value.

Classes can be inherited, but structs cannot.

Structs generally give better performance as they are stored on the stack rather than the heap.
What is the GAC (Global Assembly Cache)?
Where assemblies are stored so that many different applications can share these assemblies. Multiple versions of assemblies can be stored in the GAC, with applications specifying which version to use in the config file.
How does .NET help to manage DLLs on a system?
When you have multiple DLLs on a system, managing the DLLs can be particularly difficult if there are multiple versions of the various DLLs. In the .NET framework, assemblies are managed using the information stored in their metadata, and you can store multiple versions of each in the GAC.
What are DLLs?
A library that contains code and data that can be used by more than one program at the same time
What are the types of error that can occur in a C# program?
*Syntax error
*Logic error
*Runtime error
What is a Syntax Error?
This type of error, which is identified during compilation, occurs because the programmer has used syntax incorrectly or included a typo in the code.
What is a Logic Error?
This type of error causes the program to do something other than what the programmer intended. The program will output an unexpected result in response to tests.
What is a Runtime Error?
This type of error causes the program to crash or terminate incorrectly.