Blackrock
Swajat Interview Questions and Answers
Q1. Reverse Linked List Problem Statement
Given a singly linked list of integers, return the head of the reversed linked list.
Example:
Initial linked list: 1 -> 2 -> 3 -> 4 -> NULL
Reversed linked list: 4 -> 3 -> 2...read more
Reverse a singly linked list of integers and return the head of the reversed linked list.
Iterate through the linked list and reverse the pointers to point to the previous node instead of the next node.
Use three pointers to keep track of the current, previous, and next nodes while reversing the linked list.
Update the head of the reversed linked list as the last node encountered during the reversal process.
Yes, I can analyze SQL queries and code snippets to determine correct outputs or errors.
Understand the SQL syntax and logic to identify errors in queries.
Check for syntax errors, missing or incorrect keywords, and data type mismatches.
Analyze the code snippets to identify logical errors or potential bugs.
Compare the expected output with the provided output to determine correctness.
Joins are used to combine rows from two or more tables based on a related column, while indexing is a technique to improve the performance of queries by creating a data structure that allows for quick lookup of data.
Joins are used to retrieve data from multiple tables based on a related column, such as INNER JOIN, LEFT JOIN, RIGHT JOIN, and FULL JOIN.
Indexing involves creating data structures like B-trees or hash tables to quickly locate rows in a table, improving query perfo...read more
Python is a high-level, interpreted language known for its simplicity and readability, while C++ is a low-level, compiled language known for its performance and efficiency.
Python is dynamically typed, while C++ is statically typed.
Python uses indentation for code blocks, while C++ uses curly braces.
Python has automatic memory management, while C++ requires manual memory management.
Python is slower in execution compared to C++ due to its interpreted nature.
Python is commonly u...read more
Q5. pseudo code of finding ones in a number
Count the number of ones in a given number using pseudo code
Initialize a count variable to 0
Iterate through each bit of the number and check if it is 1
Increment the count if the bit is 1
Return the count as the result
Q6. Program of prime number
A program to find prime numbers within a given range
Iterate through numbers in the given range
Check if each number is divisible by any number other than 1 and itself
If not divisible, it is a prime number
More about working at Blackrock
Interview Process at Swajat
Top Software Developer Intern Interview Questions from Similar Companies
Reviews
Interviews
Salaries
Users/Month