Systenics Solutions
10+ Nuform Social Interview Questions and Answers
Q1. What is method overloading and overriding
Method overloading is having multiple methods in the same class with the same name but different parameters. Method overriding is redefining a method in a subclass with the same name and parameters as in the superclass.
Method overloading allows a class to have multiple methods with the same name but different parameters.
Method overriding involves redefining a method in a subclass that is already defined in the superclass.
Overloading is resolved at compile-time while overridin...read more
Q2. For example What is the difference between oops and pops What is encapsulation What are different types of polymorphism
OOPs stands for Object-Oriented Programming while POPs stands for Procedure-Oriented Programming. Encapsulation is the concept of bundling data and methods that operate on the data into a single unit. Polymorphism refers to the ability of a single function or method to operate on different types of data.
OOPs focuses on objects and classes, allowing for better organization and reusability of code.
POPs focuses on procedures and functions, which can lead to less organized and le...read more
Q3. What is pointer(Dangling pointer)
A dangling pointer is a pointer that points to a memory location that has been deallocated, leading to undefined behavior.
Dangling pointers can occur when a pointer is not set to NULL after the memory it points to is freed.
Accessing a dangling pointer can result in a crash or unexpected behavior.
Example: int *ptr = new int; delete ptr; // ptr is now a dangling pointer
Q4. What is class and object,constructors
A class is a blueprint for creating objects, and objects are instances of classes. Constructors are special methods used to initialize objects.
Class is a template that defines the properties and behaviors of objects.
Object is an instance of a class that has its own state and behavior.
Constructors are special methods used to initialize objects when they are created.
Example: Class 'Car' defines properties like 'color' and behaviors like 'drive'. Object 'myCar' is an instance of...read more
Q5. Introduction Why Java Basics of Java
Java is a popular programming language known for its platform independence and robustness.
Java is platform-independent, meaning it can run on any device with a Java Virtual Machine (JVM)
Java is object-oriented, allowing for modular and reusable code
Java has a large standard library, providing pre-built functionality for common tasks
Java is widely used in enterprise applications, web development, mobile apps, and more
Q6. java interface in actual coding
Java interfaces are used to define a contract for classes to implement, allowing for polymorphism and loose coupling.
Interfaces in Java are used to define abstract methods that must be implemented by classes that implement the interface.
Interfaces can also contain constants, default methods, and static methods.
Example: interface Animal { void eat(); } class Dog implements Animal { public void eat() { System.out.println("Dog is eating"); }}
Q7. Diff between string builder an buffer
String Builder is mutable, String Buffer is synchronized.
String Builder is faster as it is not synchronized.
String Buffer is thread-safe, String Builder is not.
String Builder should be used in single-threaded environments, String Buffer in multi-threaded.
Example: StringBuilder sb = new StringBuilder(); StringBuffer buff = new StringBuffer();
Q8. what is diif between final,finalize and finally method.
Final is a keyword used to declare a constant, finalize is a method used for cleanup operations, and finally is a block used in exception handling.
Final keyword is used to declare a constant value.
Finalize method is used for cleanup operations before an object is destroyed.
Finally block is used in exception handling to execute code after try/catch blocks.
Q9. Merge two arrays and print it
Merge two arrays of strings and print the result
Create a new array and concatenate the elements of the two arrays
Use a loop to iterate through both arrays and add elements to the new array
Print the merged array
Q10. OOPS Concept function
OOPS Concept function
OOPS (Object-Oriented Programming) is a programming paradigm that uses objects to represent and manipulate data.
Functions in OOPS are methods that are defined within a class and can be called to perform specific tasks.
Functions in OOPS encapsulate behavior and can have parameters and return values.
Functions can be public, private, or protected depending on their accessibility.
Inheritance, polymorphism, and encapsulation are key concepts in OOPS that apply...read more
Q11. What is contructor
A constructor is a special type of method in a class that is automatically called when an object of that class is created.
Constructors have the same name as the class they belong to
They are used to initialize the object's state
Constructors can have parameters to customize the initialization process
Q12. What is deadlock
Deadlock is a situation in which two or more processes are unable to proceed because each is waiting for the other to release a resource.
Occurs in multitasking environments
Caused by a circular wait, hold and wait, no preemption, and mutual exclusion
Examples include two processes waiting for each other to release a lock or resource
Q13. Sum of numbers digits
Calculate the sum of digits in a given number.
Iterate through each digit of the number and add them together.
Use modulo operator to extract each digit.
Convert the number to a string to easily access individual digits.
Q14. Abstraction vs Encapsulation
Abstraction focuses on hiding unnecessary details, while encapsulation involves bundling data and methods together.
Abstraction allows us to focus on essential details and ignore irrelevant information.
Encapsulation helps in data hiding and protecting data integrity by restricting access to certain components.
Abstraction is like a car dashboard showing only necessary information, while encapsulation is like a car engine where internal workings are hidden.
Abstraction is achieve...read more
Q15. Threads in java
Threads in Java allow for concurrent execution of multiple tasks within a single program.
Threads are lightweight sub-processes within a program.
They allow for parallel execution of tasks, improving performance.
Java provides built-in support for creating and managing threads using the Thread class.
Example: Creating a new thread - Thread myThread = new Thread(() -> { // task to be executed });
Example: Starting a thread - myThread.start();
Q16. Code for star pattern
Code to print a star pattern in the console
Use nested loops to control the number of rows and columns
Use a combination of spaces and stars to create the desired pattern
Example: for a pyramid pattern, increment the number of stars in each row
More about working at Systenics Solutions
Interview Process at Nuform Social
Top Interview Questions from Similar Companies
Reviews
Interviews
Salaries
Users/Month