In RESTful APIs, _______ is a mechanism used to control access to resources.

  • Authentication
  • Authorization
  • Decryption
  • Encryption
In RESTful APIs, Authorization is a mechanism used to control access to resources. It determines whether the authenticated user has the necessary permissions to perform a particular action on a resource.

Which caching strategy is suitable for reducing database load and improving response times for frequently accessed data?

  • Browser Caching
  • Content Delivery Network (CDN) Caching
  • Database Caching
  • Object Caching
Database Caching is a caching strategy suitable for reducing database load and improving response times for frequently accessed data. It involves storing query results or data in memory to avoid repeated database queries for the same data.

Which SDLC model is known for its linear sequential flow of phases?

  • Agile Model
  • Spiral Model
  • V-Model
  • Waterfall Model
The Waterfall Model is known for its linear sequential flow of phases. In this model, each phase must be completed before the next one begins, making it a straightforward and easy-to-understand approach. However, it may lack flexibility compared to other models.

Which command is used to create a new branch in Git?

  • git add
  • git branch
  • git checkout -b
  • git commit -m
The command git checkout -b is used to create a new branch in Git. This command creates a new branch with the specified name and switches to it, allowing developers to start working on a new feature or bug fix.

What does the === operator do in JavaScript?

  • Assignment
  • Logical AND
  • Strict equality comparison
  • Type coercion equality comparison
The === operator in JavaScript performs strict equality comparison, meaning it checks both value and type. It returns true if the operands are equal without performing type coercion.

You're working on a team project, and your feature branch diverged significantly from the main branch. Which Git command would you use to integrate your changes without creating a messy merge history?

  • git merge --no-ff
  • git merge --squash
  • git pull --rebase
  • git rebase
The correct Git command to integrate changes from a diverged feature branch without creating a messy merge history is git rebase. It helps maintain a linear and cleaner history by incorporating the changes on top of the main branch.

NoSQL databases are often used in scenarios where _______.

  • ACID compliance is required
  • Data is highly structured
  • Scalability and high-performance are crucial
  • Schema is predefined
NoSQL databases are often used in scenarios where scalability and high-performance are crucial. They excel in handling large volumes of unstructured or semi-structured data with a focus on horizontal scaling.

Which HTTP method is typically used for creating a new resource in a RESTful API?

  • DELETE
  • GET
  • POST
  • PUT
The HTTP method used for creating a new resource in a RESTful API is POST. It submits data to be processed to a specified resource.

In a project, you have a table with millions of records, and your queries are taking too long to execute. What strategies would you employ to optimize the performance of the database?

  • Indexing and Query Optimization
  • Denormalization and Partitioning
  • Caching and Replication
  • Sharding and Vertical Scaling
To optimize the performance of a database with millions of records, strategies such as indexing, query optimization, denormalization, partitioning, caching, and replication can be employed. The correct option focuses on indexing and query optimization.

You encounter a bug in your codebase. How would you use TDD principles to fix it and prevent similar issues in the future?

  • Fix the bug directly without writing tests
  • Ignore the bug and focus on adding new features
  • Write a failing test that reproduces the bug, fix the bug, and ensure the test passes
  • Write tests for unrelated features to cover more code paths
Using TDD to fix a bug involves writing a failing test that reproduces the issue, then fixing the bug to make the test pass. This ensures that the bug is addressed and helps prevent regressions by having a test in place.

In database management, what is cardinality, and how does it impact query optimization?

  • The number of rows in a table
  • The relationship between tables
  • The size of the database
  • The uniqueness of values in a column
Cardinality in database management refers to the relationship between tables. It impacts query optimization by influencing the choice of join algorithms and the order in which tables are accessed, crucial for performance.

When planning data migration, what role does data profiling play?

  • Analyzing Data Structure
  • Assessing Data Quality
  • Evaluating Network Speed
  • Identifying Data Owners
Data profiling plays a crucial role in planning data migration by assessing the quality of the data. It involves analyzing the structure, integrity, and completeness of the data to identify potential issues that may impact the migration process. This proactive step helps in creating a more accurate migration plan and ensuring successful data transfer.