The Agile principle of "delivering working software frequently" is best supported by the practice of _________.

  • Continuous Integration
  • Sprint Review
  • Test-Driven Development
  • Waterfall Model
The Agile principle of "delivering working software frequently" emphasizes the importance of delivering usable software increments regularly. Continuous Integration is a practice that aligns well with this principle, as it involves frequently integrating code changes from multiple developers into a shared repository. This integration is followed by automated tests to ensure that the software remains functional and bug-free. Sprint Review is a ceremony in Agile where the team showcases the completed work to stakeholders, but it doesn't directly relate to the continuous delivery of working software. Test-Driven Development (TDD) is a development approach where tests are written before the code, aiding in software quality but not directly addressing frequent delivery. The Waterfall Model, in contrast, is a traditional sequential development approach that doesn't prioritize frequent software delivery. Therefore, Continuous Integration is the practice that best supports the Agile principle of delivering working software frequently.

Which operation in strings is used to concatenate two strings?

  • append()
  • insert()
  • concat()
  • concatenate()
Option 3, concat(), is used to concatenate two strings. In many programming languages such as Java and JavaScript, this operation is represented by the '+' operator or specific functions/methods like concat(). It joins the contents of two strings into a single string.

The ___________ protocol is used to establish a connection-oriented communication between two hosts.

  • UDP
  • HTTP
  • TCP
  • IP
The correct option is "TCP." TCP (Transmission Control Protocol) is a connection-oriented protocol in the TCP/IP suite. It provides reliable and ordered delivery of data between two hosts by establishing a connection, acknowledging data receipt, and handling retransmissions if packets are lost. UDP (Option 1), on the other hand, is a connectionless protocol that is faster but less reliable. HTTP (Option 2) is a protocol used for web communication, operating at the Application layer. IP (Option 4) is a network layer protocol responsible for addressing and routing.

Which data structure is commonly used to represent a file system hierarchy?

  • Array
  • Queue
  • Stack
  • Tree
A file system hierarchy is commonly represented using a tree data structure. In this structure, directories (folders) are nodes, and files are the leaves or nodes without children. Each directory node can have multiple child nodes, reflecting the nested organization of files and directories within the system. This hierarchical representation facilitates efficient file navigation and management operations, such as creating, moving, and deleting files and directories.

How can dynamic programming be applied to optimize matrix multiplication?

  • Divide and Conquer
  • Dynamic Programming
  • Memoization
  • Strassen's Algorithm
Dynamic programming can optimize matrix multiplication by breaking down the problem into smaller subproblems and storing their solutions in a table (memoization). This approach reduces redundant computations and improves efficiency compared to naive methods. Techniques like Strassen's algorithm and divide and conquer can also be used, but dynamic programming specifically focuses on efficiently solving overlapping subproblems in matrix multiplication.

How does thread synchronization help in preventing race conditions?

  • Asynchronous execution, deadlock prevention
  • Mutual exclusion, critical section management
  • Parallel execution of threads, data inconsistency prevention
  • Sequential execution of threads, shared resource protection
Thread synchronization plays a crucial role in preventing race conditions by implementing mechanisms such as mutual exclusion and critical section management. These techniques ensure that only one thread can access a shared resource at a time, thereby avoiding data inconsistencies and conflicts that can arise when multiple threads attempt to modify the same data concurrently. By enforcing sequential execution or controlled access to critical sections, thread synchronization helps maintain program correctness and stability in multithreaded environments.

What is the key difference between Type 1 and Type 2 hypervisors?

  • Designed for server-level virtualization
  • Directly interacts with hardware
  • Runs on a host operating system
  • Used for application-level virtualization
Type 1 hypervisors operate directly on the underlying hardware, making them more efficient and suitable for server-level virtualization. In contrast, Type 2 hypervisors run on a host operating system, adding a layer of abstraction that can impact performance.

How does virtual memory differ from physical memory in memory management?

  • Accessible directly by the CPU
  • Exists as a logical extension of physical memory
  • Stored on secondary storage
  • Utilized primarily by the operating system for caching purposes
Virtual memory serves as a logical extension of physical memory, allowing the operating system to use secondary storage as an extension of RAM. This aids in managing larger programs and multitasking efficiently.

___________ databases are particularly suitable for storing and managing hierarchical data structures.

  • Column-Family
  • Document
  • Graph
  • Key-Value
Document databases excel at managing hierarchical data structures because they store data in a format similar to JSON or XML, allowing for nested fields and complex structures. This makes them a preferred choice for applications where data has a nested or hierarchical nature, such as content management systems, e-commerce platforms, and social media applications.

Describe the difference between symmetric and asymmetric encryption and provide scenarios where each is appropriate in web security.

  • Different Keys for Data Encoding and Decoding
  • Key Exchange for Secure Data Transfer
  • Public and Private Key Pair for Secure Communication
  • Same Key for Encryption and Decryption
Symmetric encryption uses a single key for both encryption and decryption, making it faster but requiring secure key exchange. Asymmetric encryption employs a public-private key pair, ensuring secure communication without a prior key exchange but being slower due to the complexity of operations. Symmetric encryption is suitable for data at rest, like stored files, while asymmetric encryption is ideal for secure communication over networks, such as SSL/TLS protocols.