Tutor profile: Brian D.
Subject: Web Development
What is responsive web design and why would a user of your web site care about it?
Whenever designing a user interface, whether for a web application / web site or other type of program, usability of the interface is of paramount importance. It used to be that studying something like Microsoft's user interface guidelines and implementing a UI that incorporates them was enough. But we can no longer assume anything about a user's view of your application - tablets, laptops of various sizes, resizing windows, orientation of the screen, mobile devices such as phones and watches, all have their own limitations and capabilities that must be designed around. Designing for these differences so that your application's user interface automatically adjusts layout and sizing for optimal viewing and usage on these various devices is called 'responsive design'. CSS2 (media types) and CSS3 (media queries) provide the necessary functionality for determining which styling should be applied to each device's limitations and capabilities - width/height of the viewport and device, orientation, resolution, etcetera.
Subject: SQL Programming
What is referential integrity and what do primary and foreign keys have to do with it?
Once a database has been normalized to at least the third normal form (3NF), either by design or by restructuring, risk is introduced that can result in bad data existing in the database. For example, a poorly normalized database might contain a table that contains a customer information together with the customer's current orders. A better database design would contain a customer table that includes a customer ID, and a separate table for containing the customer's orders. The orders table could refer to the customer by referencing the customer ID that is associated with the order(s) in the orders table. This is good normalization, but it also introduces the risk that orders can exist without a valid customer being associated with them. This is the problem that referential integrity is intended to solve. If the customers table has a unique customer ID for each unique customer (the Customer table Primary Key, CustomerID for example), then the Orders table can have a 'foreign key' that is the CustomerID of the Customer's table. Now, if each order that is inserted or updated in the Orders table must be contain a CustomerID value where the CustomerID must exist in the Customer table - the result being that all orders are associated with valid customers. The Orders table then has "referential integrity" with the Customer table.
Subject: C Sharp Programming
Why doesn't the C# language support multiple inheritance?
Before multiple inheritance can be implemented in the Common Language Runtime (CLR), a survey of all languages is necessary to evaluate how they each might support multiple inheritance - not all languages make the same assumptions. In terms of type casting, serialization, identity comparisons, verifiability, etcetera, multiple inheritance adds much complexity and makes it far more difficult to test and verify that your code is defect free. The risk of introducing defects into your software is much higher with multiple inheritance. It is better to use encapsulation via aggregation or composition as appropriate so types can be independently tested.
needs and Brian will reply soon.