Which type of attack involves an attacker stealing a user's session token and using it to impersonate the user?

  • Cross-Site Request Forgery (CSRF)
  • Cross-Site Scripting (XSS)
  • SQL Injection
  • Session Hijacking
Session Hijacking involves an attacker stealing a user's session token and using it to impersonate the user. This attack allows unauthorized access to sensitive data.

Which SQL clause is used to filter results based on a specified condition?

  • FROM
  • GROUP BY
  • SELECT
  • WHERE
The WHERE clause in SQL is used to filter results based on a specified condition. It allows you to specify conditions that the data must meet to be included in the result set.

In Cassandra, a _______ determines the placement of data on nodes in the cluster.

  • Consistency Level
  • Partition Key
  • Replication Factor
  • Super Column
In Cassandra, the placement of data on nodes is determined by the Partition Key. It is crucial for distributing data across the cluster efficiently.

What is the time complexity of accessing an element in an array?

  • O(1)
  • O(log n)
  • O(n)
  • O(n^2)
The time complexity of accessing an element in an array is O(1) or constant time. This is because arrays provide direct access to any element using its index, and the access time remains constant regardless of the array size.

What is the main difference between Docker and Kubernetes?

  • Docker is a containerization platform, while Kubernetes is a container orchestration platform.
  • Docker is only for development purposes, while Kubernetes is for production environments.
  • Docker is open-source, while Kubernetes is proprietary.
  • Docker manages individual containers, while Kubernetes manages clusters of containers.
The main difference between Docker and Kubernetes lies in their functionalities. Docker is primarily a containerization platform, used to package and run applications in isolated environments called containers. On the other hand, Kubernetes is a container orchestration platform that automates the deployment, scaling, and management of containerized applications. While Docker manages individual containers, Kubernetes manages clusters of containers, offering features like load balancing, auto-scaling, and self-healing.

The command "git pull" is equivalent to "git fetch" followed by _______.

  • git branch
  • git commit
  • git merge
  • git push
The command "git pull" is equivalent to "git fetch" followed by git merge. This combination fetches changes from the remote repository and merges them into the current branch. It helps in keeping your local branch up-to-date with the remote branch.

TDD encourages developers to write _______ tests to cover different aspects of the software.

  • Acceptance
  • Integration
  • System
  • Unit
TDD encourages developers to write Integration tests to cover different aspects of the software. Integration tests ensure that different components or modules work together as expected when integrated into a complete system.

In NoSQL databases, what does "CAP theorem" stand for, and what does it imply?

  • CAP stands for Capacity, Availability, Performance
  • CAP stands for Concurrency, Atomicity, Persistence
  • CAP stands for Configuration, Authentication, Portability
  • CAP stands for Consistency, Availability, Partition Tolerance
The CAP theorem in NoSQL databases stands for Consistency, Availability, and Partition Tolerance. It implies that in the presence of a network partition, a distributed system must choose between consistency and availability.

In Docker, a _______ defines the environment in which a container runs, including base image, dependencies, and commands to run.

  • Blueprint
  • Configuration
  • Dockerfile
  • Manifest
In Docker, a Dockerfile defines the environment in which a container runs. It specifies the base image, dependencies, and commands needed to create the container.

How can you center align an element horizontally using CSS?

  • align: center;
  • horizontal-align: center;
  • margin: auto;
  • text-align: center;
To center align an element horizontally in CSS, you can use margin: auto;. This property automatically distributes the remaining space on both sides of the element, centering it within its container.

In which situations is the Factory Method design pattern useful?

  • Creating objects with multiple possible representations
  • Decoupling the concrete classes from the client
  • When a class cannot anticipate the class of objects it must create
  • When the system needs to be independent of how its objects are created, composed, and represented
The Factory Method design pattern is useful when you want to decouple the client code from the concrete classes it uses, allowing flexibility in object creation without changing the client code.

RESTful APIs follow the principle of _______ over configuration.

  • Configuration
  • Convention
  • Simplicity
  • Standardization
RESTful APIs follow the principle of Convention over Configuration (CoC). This means that developers only need to specify unconventional aspects of the application. Conventions are predefined rules that simplify development and promote consistency.