Cognizant
100+ Vivid Edge Interview Questions and Answers
Q1. Check for syntax error/logical error and correct the error to get the desired output. void maxReplace(int size,int *inputList) { int i,sum=0; for(i=0;i
Fix syntax and logical errors in maxReplace function
Change 'o' to '0' in second for loop
Replace sum with inputList[i] in second for loop
Add a condition to check if inputList[i] is greater than sum in second for loop
Print sum instead of inputList[i] in third for loop
You have been given a sorted (lexical order) dictionary of an alien language. Write a function that finds the order of characters in the alien language. This dictionary will be given to you in t...read more
Q3. if you promised a customer for the product on a specific day and your company will not be able to give that product on time then how will you convince that customer ?
I would apologize for the delay and offer a solution or compensation.
Acknowledge the inconvenience caused to the customer
Explain the reason for the delay and assure them that steps are being taken to resolve it
Offer a solution or compensation to make up for the delay
Maintain open communication with the customer throughout the process
Q4. What are OOP characteristics? Difference between abstraction and encapsulation? What are types of polymorphism ?4 to 5 Question on projects which I have mentioned in cv. Write a program to find the prime factor...
read moreAnswering questions related to OOP characteristics, polymorphism, and programming projects.
OOP characteristics include inheritance, encapsulation, abstraction, and polymorphism.
Abstraction is the process of hiding implementation details while encapsulation is the process of hiding data.
Types of polymorphism include compile-time and runtime polymorphism.
Projects mentioned in CV were discussed and explained.
A program to find prime factors of a number can be written using a loop...read more
Q5. Why is java platform independent?
Java is platform independent due to its bytecode and JVM.
Java code is compiled into bytecode which is platform-independent.
JVM (Java Virtual Machine) interprets the bytecode and executes it on any platform.
This eliminates the need for recompilation of code for different platforms.
For example, a Java program compiled on Windows can run on Linux or Mac without any changes.
This makes Java highly portable and flexible.
Print the following pattern
Pattern for N = 4
The dots represent spaces.
Input Format :
N (Total no. of rows)
Output Format :
Pattern in N lines
Constraints :
0 <= N <= 50
Q7. Which programming language are you familiar with? what are the datasets in python what is the difference between list and tuple in python? write a program to find number of white spaces in a given string? what ...
read moreAnswering questions related to programming language Python.
I am familiar with Python programming language.
Datasets in Python include NumPy, Pandas, and SciPy.
List is mutable while Tuple is immutable in Python.
Program to find number of white spaces in a given string: def count_spaces(string): return string.count(' ')
While loop executes a block of code as long as the condition is true, for loop executes a block of code for a specific number of times.
Q8. If you have given a 1 kg cake and you have given 3 chance to cut and you have to distribute among 8 people how will you do that? condition is that you have to distribute it equally among 8 people.
Divide 1 kg cake equally among 8 people in 3 cuts.
Cut the cake into 8 equal pieces using 2 cuts.
Stack the pieces and cut them in half using the third cut.
Distribute the 16 pieces among 8 people.
Q9. What is the difference between Method and Function in programming language?
Method and Function are both blocks of code that perform a specific task, but the main difference is that a method is associated with an object while a function is not.
A method is called on an object, while a function is called independently.
A method can modify the state of an object, while a function cannot.
A method is defined within a class, while a function is defined outside of a class.
Example of a method: object.methodName()
Example of a function: functionName()
Q10. Write a program to check whether a string starts with 's' and if it starts with it convert it into an array named anything and print that array one by one.
Program to check if a string starts with 's' and convert it to an array
Use string method startsWith() to check if the string starts with 's'
If it starts with 's', use split() method to convert it into an array
Loop through the array and print each element
Q11. Write a program to check whether a given integer is a prime or not and even or odd and it should not give any errors for any kind of inputs.
Program to check if an integer is prime, even or odd without errors.
Take input integer from user
Check if input is valid integer
Check if input is prime or not
Check if input is even or odd
Display the result
Q12. Write a c program which will display your name in first line and from second line one word will be lesser from the previous line. Display this until one word remains
The program will display the name of the user in the first line and then decrease one word in each subsequent line until only one word remains.
Create an array of strings containing the user's name split into individual words
Use a loop to iterate through the array and print the name with one less word in each iteration
Continue the loop until only one word remains
Q13. An sql query to find salary, department of employee
An SQL query to find the salary and department of an employee.
Use the SELECT statement to retrieve the desired columns.
Specify the table name and join it with the department table using the appropriate join condition.
Use the WHERE clause to filter the results based on employee criteria if needed.
Q14. Which programming language you like the most and why?
I like Python the most because of its simplicity and versatility.
Python has a simple syntax which makes it easy to learn and use.
It has a vast library of modules and frameworks for various purposes.
Python is used in various fields such as web development, data science, and automation.
It supports both object-oriented and functional programming paradigms.
Python is also known for its readability and maintainability of code.
For example, I have used Python for web scraping, data a...read more
Q15. what is the output for the given code sample explain
The output of the code sample is 'Hello World'.
The code sample is likely to print a string.
The string being printed is 'Hello World'.
Q16. What error will you get if you enter a duplicate value to the primary key column
You will get a primary key violation error if you enter a duplicate value to the primary key column.
A primary key is a unique identifier for each record in a database table.
When you try to insert a duplicate value into the primary key column, the database system will throw an error.
The error message will typically indicate a primary key violation or duplicate key error.
To resolve the issue, you need to ensure that each value in the primary key column is unique.
Q17. Explain how the Software Development process works ? And what is it that we are following now a days ?
Software development process involves planning, designing, coding, testing, and deployment of software.
Requirement gathering and analysis
Designing the software architecture
Coding and implementation
Testing and debugging
Deployment and maintenance
Agile methodology is commonly followed nowadays
Q18. Find third lowest element from an array and count the occurrence of that number in the array.
Find third lowest element and its occurrence in an array.
Sort the array and return the element at index 2 with its count.
Use a hash table to count occurrences while iterating through the array.
Q19. What is R programming? What is Public class? What are access specifiers? Write a array program and explain it for nested loop concept?
R programming is a language and environment for statistical computing and graphics.
R programming is widely used for data analysis, statistical modeling, and visualization.
Public class in programming refers to a class that can be accessed from outside the package.
Access specifiers in programming define the accessibility of classes, methods, and variables.
An array program using nested loops can be used to iterate through a multi-dimensional array.
There was a star and at each vertex, there was a number on each vertice the number was not given so we have to find the missing number.
Q21. Under 'If' statement if more than 1 statements are there and curly brackets is not there then what will be the output?
If more than 1 statements are under 'If' statement without curly brackets, what will be the output?
The first statement after 'if' will be executed
The second statement will be executed regardless of the condition
It can lead to unexpected behavior and bugs
Always use curly brackets to avoid confusion
Q22. What is machine learning, deep learning, artificial intelligence and cloud computing?
Machine learning, deep learning, artificial intelligence and cloud computing are all related to advanced computing technologies.
Machine learning is a subset of AI that involves training algorithms to make predictions or decisions based on data.
Deep learning is a subset of machine learning that uses neural networks to learn and make decisions.
Artificial intelligence is the broader field of creating intelligent machines that can perform tasks that typically require human intell...read more
Q23. What are star and mesh topology?
Star and mesh are network topologies used in computer networking.
Star topology connects all devices to a central hub or switch.
Mesh topology connects every device to every other device.
Star topology is easy to set up and troubleshoot.
Mesh topology is highly reliable and fault-tolerant.
Examples of star topology include Ethernet and Wi-Fi networks.
Examples of mesh topology include sensor networks and peer-to-peer networks.
Q24. What is the advantage of using netbeans for writing java ?
NetBeans provides a user-friendly interface, powerful code editing features, and seamless integration with Java development tools.
NetBeans offers a user-friendly interface with drag-and-drop functionality for easy development.
It provides powerful code editing features like code completion, refactoring, and debugging.
NetBeans has seamless integration with Java development tools, making it easier to build, test, and deploy Java applications.
It supports various frameworks and te...read more
Q25. As i am from ECE, difference between half duplex and full duplex
Half duplex allows communication in both directions, but not simultaneously. Full duplex allows simultaneous communication in both directions.
Half duplex allows communication in both directions, but only one direction at a time.
Full duplex allows simultaneous communication in both directions.
Examples of half duplex communication include walkie-talkies and CB radios.
Examples of full duplex communication include telephone conversations and video conferencing.
Q26. What is difference between RDBMS and DBMS? What is differenence between stack and queue?
RDBMS is a relational database management system that stores data in tables with predefined relationships. DBMS is a general-purpose database management system that stores data in various formats.
RDBMS enforces ACID properties while DBMS does not
RDBMS supports SQL while DBMS may or may not support SQL
RDBMS is used for large-scale applications while DBMS is used for small-scale applications
Stack is a LIFO data structure while Queue is a FIFO data structure
Stack uses push and p...read more
Q27. Tell about encoder, decoder and Multiplexer
Encoders, decoders, and multiplexers are digital logic circuits used in data processing and communication systems.
An encoder is a circuit that converts a set of input signals into a coded output signal.
A decoder is a circuit that converts a coded input signal into a set of output signals.
A multiplexer is a circuit that selects one of many input signals and forwards it to a single output line.
Encoders and decoders are often used together to convert data between different forma...read more
Q28. Tell me some of the features of Java?
Java is a popular programming language known for its platform independence and object-oriented features.
Java is platform independent, meaning it can run on any platform with a Java Virtual Machine (JVM)
Java is object-oriented, allowing for encapsulation, inheritance, and polymorphism
Java has automatic memory management through garbage collection
Java has a rich set of APIs and libraries for various tasks, such as networking and GUI development
Java supports multithreading, allo...read more
Q29. Query to select the row of any table
Query to select a row from any table
Use SELECT statement with WHERE clause to specify the row to be selected
Specify the table name and column names in the SELECT statement
Use appropriate conditions in the WHERE clause to filter the rows
Example: SELECT * FROM table_name WHERE column_name = value;
Q30. Write the any coding in c language?
Here is a simple example of a C program that prints 'Hello, World!'
Declare a main function
Use the printf function to print 'Hello, World!'
Return 0 to indicate successful execution
Q31. What is an object?can you explain with an example?
An object is an instance of a class that encapsulates data and behavior.
Objects have attributes (data) and methods (behavior).
Objects can interact with each other through method calls.
Example: A car object has attributes like color, make, and model, and methods like start and stop.
Objects promote code reusability and modularity.
Q32. What is a latch-up in communications?
Latch-up is a phenomenon in which a circuit becomes stuck in a high-current state.
It occurs when a parasitic thyristor is inadvertently created within a circuit
It can cause permanent damage to the circuit
It can be prevented by using proper design techniques and layout
Example: A latch-up can occur in a microcontroller when a voltage spike causes the input to exceed the maximum rating
Q33. What is encapsulation
Encapsulation is the process of hiding implementation details and providing a public interface for accessing the functionality.
Encapsulation helps in achieving data abstraction and information hiding
It prevents unauthorized access to the internal details of an object
It allows for better control over the data and its behavior
Example: A bank account class may have private variables for account number and balance, but provide public methods for deposit and withdrawal
Example: A c...read more
Q34. what are oops and explain them with real time example?
OOPs stands for Object-Oriented Programming. It is a programming paradigm based on the concept of objects.
OOPs is based on the concept of classes and objects.
It focuses on encapsulation, inheritance, and polymorphism.
Real-time examples of OOPs include a car, a bank account, and a smartphone.
In a car, the engine, wheels, and other components are objects, and the car itself is a class.
In a bank account, the account holder's name, account number, and balance are objects, and the...read more
Q35. what is a circular linked list?
A circular linked list is a linked list where the last node points to the first node, forming a loop.
Each node has a pointer to the next node and the last node points to the first node
Traversal can start from any node and continue until the starting node is reached again
Used in applications where data needs to be accessed in a circular manner, such as a playlist
Q36. What is the main features of object oriented programming?
Object oriented programming features include encapsulation, inheritance, and polymorphism.
Encapsulation: bundling of data and methods that operate on that data within a single unit
Inheritance: ability of a class to inherit properties and methods from a parent class
Polymorphism: ability of objects to take on multiple forms or behaviors depending on the context
Example: Java, C++, Python
Q37. What is the difference between primary and secondary winding
Primary winding is the input coil while secondary winding is the output coil in a transformer.
Primary winding is connected to the input voltage source
Secondary winding is connected to the load
Primary winding has fewer turns than secondary winding
Secondary winding has higher voltage than primary winding
Q38. Give some examples where mechanical engineering and IT can work together.
Mechanical engineering and IT can work together in various fields.
Designing and simulating mechanical systems using computer-aided design (CAD) software
Developing and implementing control systems for mechanical devices using programming languages
Using sensors and data analysis to optimize mechanical systems
Creating virtual reality simulations for training and testing mechanical systems
Developing software for 3D printing and additive manufacturing
Integrating IT systems with ma...read more
Q39. Difference between Java and c++?
Java is a high-level, object-oriented programming language, while C++ is a low-level, general-purpose programming language.
Java is platform-independent, while C++ is platform-dependent.
Java has automatic memory management (garbage collection), while C++ requires manual memory management.
Java supports multithreading and exception handling by default, while C++ requires explicit implementation.
Java has a simpler syntax and is easier to learn, while C++ offers more control and p...read more
Q40. What is Repeater in Communications?
A repeater is a device that receives a signal and retransmits it at a higher power or to an extended range.
Repeater is used to extend the range of a signal in communication.
It receives a signal and amplifies it before retransmitting it.
It can be used in radio, television, and telephone communication.
Example: Wi-Fi range extenders act as repeaters to boost the signal strength and extend the coverage area.
Q41. Give the logic of push and pop in stacks?
Push adds an element to the top of the stack and pop removes the top element from the stack.
Push increases the stack size by 1 and places the new element at the top.
Pop removes the top element and decreases the stack size by 1.
Stack follows LIFO (Last In First Out) principle.
Q42. What are oops and explain all briefly?
Object-oriented programming concepts including encapsulation, inheritance, polymorphism, and abstraction.
Encapsulation: bundling data and methods that operate on the data into a single unit (class)
Inheritance: ability of a class to inherit properties and behavior from another class
Polymorphism: ability to present the same interface for different data types
Abstraction: hiding the complex implementation details and showing only the necessary features
Q43. Do you want to work in Testing though seems like you have a good coding background?
Yes, I am open to working in Testing despite having a strong coding background.
I believe that having experience in testing will make me a more well-rounded programmer.
Working in testing will help me understand the software development process from a different perspective.
I am open to learning new skills and gaining experience in different areas of software development.
Q44. What is normalisation in SQL, write a SQL query to select contents from a table.
Normalization is the process of organizing data in a database to reduce redundancy and improve data integrity.
Normalization involves breaking down a table into smaller tables and defining relationships between them.
There are different levels of normalization, with each level having specific rules to follow.
A SQL query to select contents from a table would be: SELECT * FROM table_name;
Normalization helps to prevent data inconsistencies and anomalies.
Normalization can improve d...read more
Q45. What are the steps to create a table in SQL and display the output?
Steps to create a table in SQL and display the output
Connect to the database using a tool like SQL Server Management Studio
Write a CREATE TABLE statement with table name and column definitions
Execute the SQL query to create the table
Use SELECT * FROM table_name to display the table output
Q46. what do you mean by tcp/ip?
TCP/IP stands for Transmission Control Protocol/Internet Protocol. It is a set of protocols that allows computers to communicate over the internet.
TCP/IP is a suite of communication protocols used for transmitting data over networks.
It provides reliable, connection-oriented communication between devices.
TCP is responsible for breaking data into packets, ensuring they are delivered in order and error-free.
IP handles the addressing and routing of packets across the internet.
Exa...read more
Q47. What is bst? What is different typr of binary tree?
BST stands for Binary Search Tree. It is a type of binary tree used for searching and sorting operations.
BST is a binary tree where each node has at most two children.
In a BST, the left subtree of a node contains only nodes with keys lesser than the node's key, and the right subtree contains only nodes with keys greater than the node's key.
Some examples of BST are AVL tree, Red-Black tree, and Splay tree.
Q48. Write the code block to print 4 stars , 3stars, 2stars, 1 star line by line ?
Code block to print decreasing number of stars line by line
Use a loop to iterate from 4 to 1
Inside the loop, print the number of stars based on the current iteration
Use string concatenation to print the stars on the same line
Q49. What is artificial intelligence?
Artificial intelligence is the simulation of human intelligence processes by machines, especially computer systems.
AI involves machines learning from data, recognizing patterns, and making decisions.
Examples include virtual assistants like Siri, self-driving cars, and recommendation systems like Netflix.
AI can be categorized into narrow AI (specific tasks) and general AI (human-like intelligence).
Q50. explain hello world in details why public static is used why it it important
public static is used in Java to define a method that can be called without creating an instance of the class.
public static is used in Java to define a method that belongs to the class itself, rather than to any specific instance of the class.
public static methods can be called directly using the class name, without needing to create an object of the class.
In the 'Hello World' program, public static is used to define the main method, which is the entry point of the program.
Us...read more
Q51. How to add two numbers without using + operator?
Adding two numbers without using + operator
Use bitwise operators like XOR, AND, and left shift to perform addition
Addition can be done recursively until there is no carry left
Example: 5 + 3 = 8 can be done as 5 XOR 3 = 6, 5 AND 3 = 1, 1 left shift 1 = 2, 6 + 2 = 8
Q52. write a code to swap 2 numbers without using pointer, using function
Code to swap 2 numbers without using pointer, using function
Create a function that takes two integer parameters
Inside the function, swap the values of the parameters using a temporary variable
Return the swapped values
Call the function and pass the two numbers to be swapped as arguments
Q53. What will you do if the technology you are working obsoletes.
I will adapt and learn new technologies to stay relevant in the industry.
Research and analyze emerging technologies
Attend training and workshops to learn new skills
Collaborate with colleagues to share knowledge and expertise
Update resume and portfolio to showcase new skills
Stay proactive and open-minded towards change
Q54. what is form factor, difference between generator and alternator
Form factor is the ratio of RMS value to average value of a waveform. Generator converts mechanical energy to electrical energy while alternator converts electrical energy to mechanical energy.
Form factor is a measure of waveform distortion
Generator produces DC or AC power by converting mechanical energy
Alternator produces AC power by converting mechanical energy
Generator has a commutator while alternator has slip rings
Examples of generators are hydroelectric power plants and...read more
Q55. Prime numbers coding question in any language?
A prime number is a number that is only divisible by 1 and itself.
Loop through numbers 2 to n-1 and check if n is divisible by any of them
Use the modulo operator to check for divisibility
Optimization: only check up to the square root of n
Q56. What is inheritance in Java?
Inheritance is a mechanism in Java where a class acquires the properties and methods of another class.
It allows for code reusability and promotes a hierarchical structure of classes.
The subclass inherits all the non-private members (fields, methods) of the superclass.
The keyword 'extends' is used to create a subclass.
Example: class Dog extends Animal { ... }
Multiple inheritance is not allowed in Java.
Q57. Do you know C Programming?
Yes, I know C Programming.
I have experience in writing programs in C language.
I am familiar with the syntax and structure of C language.
I have worked on projects using C language, such as developing a simple calculator program.
I am comfortable with concepts such as pointers, arrays, and structures in C language.
Q58. Program to print the prime numbers between 1 to n
Program to print prime numbers between 1 to n.
Iterate from 2 to n and check if each number is prime
A number is prime if it is only divisible by 1 and itself
Use a nested loop to check if the number is divisible by any number between 2 and itself-1
If not divisible, print the number as prime
Q59. Explain any two OOPs concept with real life example?
Encapsulation and Inheritance are two OOPs concepts with real-life examples.
Encapsulation: Wrapping data and methods into a single unit. Example: A car's engine is encapsulated as a single unit, and the driver only interacts with it through the dashboard controls.
Inheritance: Creating a new class from an existing class. Example: A sports car is a subclass of a car, inheriting all the properties and methods of a car but with additional features specific to sports cars.
Q60. Explain linked list,stack and queue concept
Linked list, stack, and queue are data structures used to store and manipulate data.
Linked list is a collection of nodes where each node points to the next node. Example: Singly linked list, Doubly linked list.
Stack is a LIFO (Last In First Out) data structure. Example: Undo/Redo functionality in text editors.
Queue is a FIFO (First In First Out) data structure. Example: Print queue in a printer.
Q61. Whats the difference between sql union and union all
SQL UNION combines and removes duplicates, UNION ALL combines without removing duplicates.
UNION merges the results of two or more SELECT statements into a single result set
UNION ALL includes all the rows from each SELECT statement, including duplicates
UNION removes duplicates from the result set, while UNION ALL does not
UNION requires the same number of columns in all SELECT statements, while UNION ALL does not have this requirement
Q62. What is dynamic memory allacation and its types ?
Dynamic memory allocation is the process of allocating memory during runtime.
It allows programs to allocate memory as needed, rather than at compile time.
Types include malloc(), calloc(), realloc(), and free().
malloc() allocates a block of memory of specified size.
calloc() allocates a block of memory for an array of elements, initializing them to zero.
realloc() changes the size of a previously allocated block of memory.
free() deallocates the memory previously allocated by mal...read more
Q63. What is an Integrated Circuit?
An Integrated Circuit is a miniaturized electronic circuit consisting of interconnected semiconductor devices.
ICs are used in almost all electronic devices
They can be analog, digital or mixed-signal
ICs can be classified as SSI, MSI, LSI or VLSI based on the number of transistors they contain
Examples of ICs include microprocessors, memory chips, and amplifiers
Q64. What is shortest path algorithm
Shortest path algorithm is used to find the shortest path between two points in a graph.
It is commonly used in GPS navigation systems.
Dijkstra's algorithm and Bellman-Ford algorithm are two popular shortest path algorithms.
The algorithm works by exploring all possible paths and selecting the one with the lowest cost.
The cost can be distance, time, or any other metric depending on the problem.
Shortest path algorithms are used in various fields such as transportation, network r...read more
Q65. Explain the Oops concepts in detail with real-world examples.
Object-oriented programming concepts with real-world examples.
Encapsulation: Hiding implementation details of a class. Example: A car's engine is encapsulated.
Inheritance: A class inheriting properties and methods from another class. Example: A dog is an animal.
Polymorphism: Ability of an object to take many forms. Example: A shape can be a circle, square, or triangle.
Abstraction: Focusing on essential features of an object. Example: A TV remote has buttons for essential func...read more
Q66. What is primary key and foriegn key
Primary key uniquely identifies a record in a table, while foreign key refers to a field in another table.
Primary key is used to enforce data integrity and ensure uniqueness of records
Foreign key is used to establish a relationship between two tables
Example: CustomerID in Orders table is a foreign key that references the Customer table's primary key
Foreign key constraints ensure referential integrity
Q67. What is the difference between c and c++?
C++ is an extension of C with object-oriented programming features.
C++ supports object-oriented programming while C does not.
C++ has classes and templates while C does not.
C++ has better support for exception handling than C.
C++ has a standard library that includes many useful functions.
C++ is more complex than C and can be harder to learn.
Q68. Write a program to check for palindrome.
A program to check if a given string is a palindrome or not.
Remove all spaces and convert the string to lowercase for accurate results.
Compare the first and last characters of the string, then move towards the center.
If all characters match, the string is a palindrome.
If any character doesn't match, the string is not a palindrome.
Q69. What is example of python IDE ?
PyCharm is a popular Python IDE.
PyCharm is a powerful and feature-rich IDE for Python development.
It provides intelligent code completion, debugging tools, and version control integration.
Other examples of Python IDEs include Visual Studio Code, Spyder, and Jupyter Notebook.
Q70. Why we use object oriented programming?
Object oriented programming allows for modular, reusable, and maintainable code.
Encapsulation allows for data hiding and protects code from external interference.
Inheritance allows for code reuse and promotes consistency.
Polymorphism allows for flexibility and extensibility.
Objects can be easily tested and debugged.
Object oriented programming promotes code organization and readability.
Examples include Java, Python, and C++.
Q71. What is inheritance and why we use it?
Inheritance is a mechanism in object-oriented programming where a new class is created by inheriting properties of an existing class.
Inheritance allows code reusability and saves time and effort in writing new code.
The existing class is called the parent or base class, and the new class is called the child or derived class.
The child class inherits all the properties and methods of the parent class and can also add new properties and methods.
For example, a class 'Vehicle' can ...read more
Q72. write a basic query to fetch data from a table ?
Basic query to fetch data from a table in SQL
Use SELECT statement to fetch data
Specify the columns you want to retrieve after SELECT
Specify the table name after FROM
Q73. Why we are doing normalization ?
Normalization is done to eliminate data redundancy and improve data integrity.
To avoid data duplication
To reduce storage space
To improve data consistency
To prevent update anomalies
To simplify queries
To follow database design principles
To ensure data accuracy and reliability
Q74. What are cypher technique and explain cypher
Cypher is a cryptographic technique used to encrypt and decrypt data.
Cypher is a method of encoding information to keep it secure from unauthorized access.
It involves using algorithms to transform plaintext into ciphertext, and vice versa.
Examples of cypher techniques include AES, DES, and RSA.
Q75. What is object oriented programming language
Object oriented programming language is a type of programming language that uses objects and classes to organize code.
Uses objects and classes to model real-world entities
Encapsulates data and behavior within objects
Supports inheritance, polymorphism, and encapsulation
Examples include Java, C++, Python
Q76. Write a Query to find the prime number upto n using python
Query to find prime numbers up to n using Python
Use a for loop to iterate through numbers up to n
Check if each number is prime by dividing it by numbers up to its square root
If the number is only divisible by 1 and itself, it is prime
Q77. What is method Overloading and method overriding
Method overloading is when multiple methods have the same name but different parameters. Method overriding is when a subclass provides a specific implementation of a method that is already provided by its superclass.
Method overloading allows a class to have multiple methods with the same name but different parameters.
Method overriding occurs in a subclass when a method has the same name, return type, and parameters as a method in its superclass.
Example of method overloading: ...read more
Q78. Projects done, write a code whether a number is odd or even
Code to check if a number is odd or even
Use the modulo operator (%) to check if the remainder is 0 or 1
If remainder is 0, number is even. If remainder is 1, number is odd
Example: int num = 5; if(num % 2 == 0) { //even number } else { //odd number }
Q79. What is dbms and what are joins please explain.
DBMS stands for Database Management System. Joins are used to combine rows from two or more tables based on a related column between them.
DBMS is a software system that allows users to define, create, maintain and control access to databases.
Joins in DBMS are used to retrieve data from multiple tables based on a related column between them.
Common types of joins include INNER JOIN, LEFT JOIN, RIGHT JOIN, and FULL JOIN.
Example: SELECT * FROM table1 INNER JOIN table2 ON table1.c...read more
Q80. What are the different types of joins in SQL?
Different types of joins in SQL include inner join, left join, right join, and full outer join.
Inner join: Returns rows when there is a match in both tables.
Left join: Returns all rows from the left table and the matched rows from the right table.
Right join: Returns all rows from the right table and the matched rows from the left table.
Full outer join: Returns rows when there is a match in either table.
Q81. What are the types of index
Indexes are used to improve database performance. There are mainly two types of indexes: clustered and non-clustered.
Clustered index determines the physical order of data in a table. A table can have only one clustered index.
Non-clustered index is a separate structure from the data table that stores the indexed columns and a pointer to the data row.
Other types of indexes include unique, full-text, filtered, and XML indexes.
Indexes can be created on one or more columns of a ta...read more
Q82. Can you write the code for bubble sort ?
Bubble sort is a simple sorting algorithm that repeatedly steps through the list, compares adjacent elements and swaps them if they are in the wrong order.
Start by comparing the first two elements of the array and swap them if necessary
Continue comparing adjacent elements and swapping them until the entire array is sorted
Repeat this process for each element in the array until no more swaps are needed
Q83. What is difference between tupple and list?
Tuples are immutable and ordered collections, while lists are mutable and ordered collections in Python.
Tuples are created using parentheses () while lists are created using square brackets []
Tuples are immutable, meaning their elements cannot be changed once assigned, while lists are mutable and can be modified
Tuples are faster than lists for accessing elements, but lists are more flexible for operations like adding or removing elements
Example: tuple = (1, 2, 3) and list = [...read more
Q84. Tell me something about image processing
Image processing involves manipulating digital images to improve their quality or extract useful information.
Image enhancement: improving the quality of an image by adjusting brightness, contrast, etc.
Image restoration: removing noise or other imperfections from an image.
Image segmentation: dividing an image into multiple segments for analysis.
Object detection: identifying and locating objects within an image.
Pattern recognition: identifying patterns or objects based on prede...read more
Q85. what technology you want to work with
I am interested in working with web development technologies such as JavaScript, React, and Node.js.
JavaScript
React
Node.js
Q86. How wifi works how Bluetooth works
WiFi and Bluetooth are wireless communication technologies that allow devices to connect and exchange data.
WiFi uses radio waves to transmit data over a network, typically using a router or access point.
Bluetooth uses short-range radio waves to connect devices directly to each other.
WiFi operates on a larger scale, covering larger areas and allowing multiple devices to connect simultaneously.
Bluetooth operates on a smaller scale, typically connecting two devices in close prox...read more
Q87. What do you know about Big data tech
Big data tech refers to technologies and tools used to process and analyze large volumes of data to extract valuable insights.
Big data tech includes tools like Hadoop, Spark, and Kafka for processing and storing large datasets.
It involves technologies like data mining, machine learning, and predictive analytics to extract insights from data.
Big data tech is used in various industries like finance, healthcare, and e-commerce to make data-driven decisions.
Examples of big data a...read more
Q88. Can you explain the 4 pillars of oops
The 4 pillars of OOP are Abstraction, Encapsulation, Inheritance, and Polymorphism.
Abstraction: Hiding implementation details and showing only necessary information.
Encapsulation: Binding data and functions together to protect data from outside interference.
Inheritance: Creating new classes from existing ones, inheriting properties and methods.
Polymorphism: Using a single interface to represent different types of objects.
Q89. What is the rating of a transformer ?
The rating of a transformer refers to its power capacity and is typically expressed in volt-amperes (VA) or kilovolt-amperes (kVA).
The rating of a transformer determines the maximum amount of power it can handle.
It is important to select a transformer with a rating that matches the power requirements of the load.
Transformer ratings can vary widely depending on the application, from small transformers used in electronic devices to large power transformers used in electrical gr...read more
Q90. What is front end ,sql ,c language, css,html, db
Front end refers to the user interface of a software application. SQL is a database management language. C is a programming language. CSS and HTML are used for designing web pages. DB stands for database.
Front end - user interface of software
SQL - database management language
C - programming language
CSS/HTML - used for designing web pages
DB - stands for database
Q91. what do you know about cts?
CTS is a multinational IT services company headquartered in India.
CTS stands for Cognizant Technology Solutions.
It provides services in areas like digital, technology, consulting, and operations.
It has a global presence with offices in over 40 countries.
CTS is one of the largest IT services companies in the world.
It has been ranked among the top companies for employee satisfaction and diversity.
Q92. What are iterations?
Iterations are repetitive processes in programming that allow for the execution of a block of code multiple times.
Iterations are used to perform a task repeatedly until a certain condition is met.
They are commonly used in loops such as for, while, and do-while loops.
Iterations can also be used to iterate over data structures such as arrays and lists.
Examples of iterations include printing numbers from 1 to 10, summing the elements of an array, and searching for a specific val...read more
Q93. what is a database?
A database is a structured collection of data that is organized and stored for easy access, retrieval, and management.
A database is used to store and manage large amounts of data.
It provides a way to organize and structure data for efficient storage and retrieval.
Databases can be relational, object-oriented, or hierarchical, depending on the data model used.
They support operations like inserting, updating, deleting, and querying data.
Examples of databases include MySQL, Oracl...read more
Q94. Explain the concept of Oops and what is a database
OOPS is a programming paradigm that focuses on objects and their interactions. A database is a structured collection of data.
OOPS stands for Object-Oriented Programming System
It emphasizes the use of objects, classes, and inheritance
Encapsulation, polymorphism, and abstraction are key principles of OOPS
A database is a system for storing and managing structured data
It allows for efficient data retrieval, manipulation, and organization
Relational databases, like MySQL, use table...read more
Q95. tell me about if and function...
If statements are used to make decisions in programming based on a condition. Functions are blocks of code that can be called and executed.
If statements are used to execute a block of code only if a specified condition is true.
Functions are reusable blocks of code that can be called multiple times.
Example: if (x > 5) { // do something }
Example: function addNumbers(a, b) { return a + b; }
Q96. What is polymorphism?
Polymorphism is the ability of an object to take on many forms.
Polymorphism allows objects of different classes to be treated as if they are of the same class.
It can be achieved through method overloading or method overriding.
Example: A parent class Animal can have child classes like Dog, Cat, and Cow. All of them can have a method called 'makeSound', but each of them will make a different sound.
Polymorphism helps in achieving code reusability and flexibility.
Q97. What is JVM,JDK,Abstraction?
JVM is a virtual machine that executes Java bytecode. JDK is a software development kit for Java. Abstraction is a concept of hiding implementation details.
JVM stands for Java Virtual Machine and is responsible for executing Java bytecode.
JDK stands for Java Development Kit and is a software development kit for Java.
Abstraction is a concept of hiding implementation details and exposing only necessary information.
Abstraction is achieved through interfaces and abstract classes ...read more
Q98. Write a program for a number is prime or not
Program to check if a number is prime or not
A prime number is only divisible by 1 and itself
Loop through numbers from 2 to n-1 and check if n is divisible by any of them
If n is divisible by any number, it is not prime
If n is not divisible by any number, it is prime
Q99. Write any program demonstrating the use of the Double pointer.
A program demonstrating the use of Double pointer.
Double pointer is a pointer that points to another pointer.
It is used to allocate memory dynamically.
It is also used in multi-dimensional arrays.
Example: int **ptr; //declaration of double pointer
Q100. What are lists? What are data structures?
Lists are a collection of ordered elements. Data structures are ways of organizing and storing data.
Lists are used to store and manipulate data in a specific order.
Data structures are used to organize and store data in a way that makes it easy to access and manipulate.
Examples of data structures include arrays, stacks, queues, and trees.
More about working at Cognizant
Top HR Questions asked in Vivid Edge
Interview Process at Vivid Edge
Reviews
Interviews
Salaries
Users/Month