CPT 231 Final Exam Review Questions With 100% Correct Answers
CPT 231 Final Exam Review Questions With 100% Correct Answers a.) The class that defines the object b.) The interface that the object implements c.) Any subclass of the class that defines the object **d.) All of the above - answerA variable that stores an object that implements an interface can be declared as which of the following data types? "Order" is displayed in a message box. - answerWhat happens when the code that follows is executed? Order order = new Order(); order.Print(); you can decide whether the clone refers to the same or a different Customer object - answerIf you implement the ICloneable interface for an Invoice that has a property that represents a Customer object, IPrintable p = new IPrintable(); - answerpublic interface IPrintable { void Print(); } public class Printer { public static void Print(IPrintable p) { MessageBox.Show("Print"); p.Print(); } } public class Order : IPrintable { public void Print() { MessageBox.Show("Order"); } } public class Transaction { } public class Rental : Transaction, IPrintable { public void Print() { MessageBox.Show("Rental"); } } Which of the following statements will definitely not compile? A class can only implement a single interface. - answerWhich of the following statements about interfaces is not true? "Print" is displayed in a message box and then "Rental" is displayed in a second message box. - answerWhat happens when the code that follows is executed? Rental r = new Rental(); Printer.Print(r); returns an object type - answerThe ICloneable interface defines a Clone method that accepts a specific type as a parameter - answerThe IComparable<> interface defines a CompareTo method that primary keys - answerWhat does a relational database use to uniquely identify each row in a table? To manage the flow of data between a client program and a database - answerWhat is the primary function of a data adapter? DataAdapter object - answerWhen you drag a data source onto a form, it adds a DataGridView control to the form and it adds all but one of the objects that follow to the Component Designer tray. Which object is it? the clients, the server, and the network - answerThe hardware components of a typical multi- user system are SqlException class - answerThe Fill method of a table adapter object that's working with a SQL Server database will throw errors of the command - answerWhat object does ADO.NET use to store a SQL statement? code exception handlers for DataError events - answerWhen you use a data source with individual controls instead of a DataGridView control, you can do all but one of the following. Which one is it? an inner join - answerA join that returns records from related tables only if their related fields match is called SQL queries - answerTo communicate with a DBMS, the application software sends foreign keys - answerWhat does a relational database use to relate tables in the database to each other? the generated SQL statements - answerBecause Visual Studio uses a disconnected data architecture when you use data sources, optimistic concurrency is implemented by alphabetically starting with Z - answerSelect VendorName, InvoiceNumber, InvoiceDate, InvoiceTotal From Vendors Inner Join Invoices On Vendors.VendorID = Invoices.VendorID Where InvoiceTotal >= 500 Order By VendorName Desc
Written for
- Institution
- CPT
- Course
- CPT
Document information
- Uploaded on
- April 16, 2024
- Number of pages
- 16
- Written in
- 2023/2024
- Type
- Exam (elaborations)
- Contains
- Questions & answers
Subjects
-
cpt 231 final exam review questions with 100 corr
Also available in package deal