Computing & Informatics - short answer type questions from AMIE exams

Explain method overloading in C using an example.
C++ Overloading (Operator and Function) C++ allows you to specify more than one definition for a function name or an operator in the same scope, which is called function overloading and operator overloading respectively.

How is a compiler different from a language translator?
Compiler converts the program from one computer language to another computer language that is translating from a higher-level language to a lower-level language. A translator translates one language to many other languages or else we can say a translator is usually translating from a high-level language to another high-level language, or from a low-level language to a high-level language.

Write two important advantages of using a DBMS as compared to using a file for storing data.
Compared to the File Based Data Management System, Database Management System has many advantages. Some of these advantages are given below −
  • Reducing Data Redundancy: The file-based data management systems contained multiple files that were stored in many different locations in a system or even across multiple systems. Because of this, there were sometimes multiple copies of the same file which lead to data redundancy.  This is prevented in a database as there is a single database and any change in it is reflected immediately. Because of this, there is no chance of encountering duplicate data.
  • Sharing of Data: In a database, the users of the database can share the data among themselves. There are various levels of authorisation to access the data, and consequently, the data can only be shared based on the correct authorisation protocols being followed.  Many remote users can also access the database simultaneously and share the data between themselves.
  • Data Integrity: Data integrity means that the data is accurate and consistent in the database. Data Integrity is very important as there are multiple databases in a DBMS. All of these databases contain data that is visible to multiple users. So it is necessary to ensure that the data is correct and consistent in all the databases and for all the users. 
  • Data Security: Data Security is a vital concept in a database. Only authorised users should be allowed to access the database and their identity should be authenticated using a username and password. Unauthorised users should not be allowed to access the database under any circumstances as it violates the integrity constraints.
  • Privacy: The privacy rule in a database means only the authorized users can access a database according to its privacy constraints. There are levels of database access and a user can only view the data he is allowed to. For example - In social networking sites, access constraints are different for different accounts a user may want to access.
  • Backup and Recovery: Database Management System automatically takes care of backup and recovery. The users don't need to backup data periodically because this is taken care of by the DBMS. Moreover, it also restores the database after a crash or system failure to its previous condition. 
  • Data Consistency: Data consistency is ensured in a database because there is no data redundancy. All data appears consistently across the database and the data is the same for all the users viewing the database. Moreover, any changes made to the database are immediately reflected by all the users and there is no data inconsistency.
Write two advantages of using client-server software over monolithic software.
  • Easy to implement and optimize performance. 
  • Do not have compatibility or Context switching issues. 
  • The cost of deployment is less. e.g.- development and management cost.
Write two important ways in which a system software differs from application software.
Application software is computer software designed to help the user to perform specific tasks. 
System software is computer software designed to operate the computer hardware and to provide a platform for running application software. System software is also known as the operating system and includes Microsoft Windows, Apple's OSX and Linux, while application software refers to programs that perform tasks and includes Microsoft Office, Adobe Photoshop and Apple iTunes. 
Application software requires an operating system to be installed and booted up before it can be used.

What do you mean by "throughput" of an operating system?
In a computer context, throughput is the amount of work that a computer can do in a given period of time. The work can be measured in terms of the amount of data processed or transferred from one location to another by a computer, computer network or computer component.

Give one factor that makes cache memory faster than main memory.
In the case of a CPU cache, it is faster because it's on the same die as the processor. In other words, the requested data doesn't have to be bussed over to the processor; it's already there. In the case of the cache on a hard drive, it's faster because it's in solid-state memory, and not still on the rotating platters. In the case of the cache on a website, it's faster because the data has already been retrieved from the database (which, in some cases, could be located anywhere in the world). So it's about locality, mostly. Cache eliminates the data transfer step.

What do you mean by the word length of a computer?
"Word size" refers to the number of bits processed by a computer's CPU in one go (these days, typically 32 bits or 64 bits). Data bus size, instruction size, address size are usually multiples of the word size.

What is the difference between a compiler and an interpreter?
A compiler searches all the errors of a program and lists them. If the program is error-free then it converts the code of the program into machine code and then the program can be executed by separate commands. An interpreter checks the errors of a program statement by statement.

---
The study material for AMIE/B Tech/Junior Engineer exams is available at https://amiestudycircle.com

Comments

Popular posts from this blog

Thermodynamics (Compressible Flow)

Thermodynamics (Fuels and Combustions)

Steel Structures - Plate Girders