Tutor profile: Wolfgang H.
Subject: Web Development
Why is it more important to keep file sizes small in web development than in regular desktop or mobile development.
Explain Atomicity in database transactions and why it is important for a database to implement it.
Atomicity is an all or nothing approach to database transactions to ensure correctness in a database. It ensures that either all of the queries in a transaction happen altogether or none happen. For example, if a bank wanted to transfer money from one account to a different account it would need to do 2 update queries. The first to subtract money from the first account and the second to add the same amount of money to the receiving account. Atomicity is necessary in this transaction because we need to ensure that if money is taken from the first account, then that money has to be added to the receiving account. If either of those updates fail the bank needs to ensure that the other update doesn't happen.
Subject: Computer Science (General)
Explain the concept of polymorphism in object oriented languages and why it is useful.
Polymorphism is a feature of object oriented languages to give classes and objects multiple forms to be bunched together with. Polymorphism is used in object oriented languages to create an umbrella super type around many different classes. For example in Java you might have classes for different shapes with functions to calculate the area of each, such as Triangles, Circles and Rectangles. If you wanted to store all the shapes under one list, you could make each of those classes a subclass under an abstract Shape class that would have a function for getting the area. You could then make a list of Shape objects and add any object that is a subclass of Shape to that list as well.
needs and Wolfgang will reply soon.