Filter interviews by
Hot and Cold Flow is a design pattern used in Android development to manage the flow of data between components.
Hot Flow refers to the flow of data that is actively being observed and updated in real-time.
Cold Flow refers to the flow of data that is not actively being observed and updated, but can be retrieved when needed.
Hot Flow is typically used for real-time updates, while Cold Flow is used for fetching data o...
Coroutines in Android can be launched using the 'launch' function from the CoroutineScope.
Use the 'launch' function from the CoroutineScope to start a coroutine.
Specify the context in which the coroutine should run, such as Dispatchers.Main for the main thread.
Handle exceptions within the coroutine using try-catch blocks.
Example: CoroutineScope(Dispatchers.Main).launch { // coroutine code here }
RecyclerView is more efficient for displaying large datasets and supports various layout managers, while ListView is simpler and easier to implement.
RecyclerView is more efficient for displaying large datasets as it only creates enough views to fill the screen, while ListView creates all views at once.
RecyclerView supports various layout managers like LinearLayoutManager, GridLayoutManager, and StaggeredGridLayout...
Hashcode is a unique identifier for an object, equals() compares the content of two objects, and == checks if two references point to the same object.
Hashcode is an integer value generated by a hashing algorithm to uniquely identify an object.
equals() method is used to compare the content of two objects for equality.
== operator checks if two references point to the same object in memory.
Example: String class overr...
LateInit is used for non-nullable properties that are initialized later, while Lazy is used for properties that are initialized only once when accessed.
LateInit is used for non-nullable properties that are initialized later in the code.
Lazy is used for properties that are initialized only once when accessed, making it suitable for expensive operations.
LateInit properties must be initialized before accessing, while...
HashMap is unordered, LinkedHashMap maintains insertion order.
HashMap does not maintain insertion order, LinkedHashMap maintains insertion order.
HashMap allows one null key and multiple null values, LinkedHashMap allows one null key and multiple null values.
HashMap is faster for iteration, LinkedHashMap is slower due to maintaining order.
Back stack is a stack of activities in Android that keeps track of the navigation history.
Back stack is managed by the Android system to handle the navigation flow of activities.
When a new activity is started, it is pushed onto the back stack.
Pressing the back button pops the top activity off the stack and navigates to the previous activity.
Activities in the back stack can be brought to the foreground by using the...
Activity is a single focused thing that user can do, while Fragment is a modular section of an activity.
Activity represents a single screen with a user interface, while Fragment represents a behavior or a portion of user interface in an Activity.
An Activity can contain multiple Fragments, but a Fragment cannot exist independently without an Activity.
Fragments have their own lifecycle, while they are dependent on t...
The view is attached to the Fragment during the onAttach() lifecycle event.
The onAttach() method is called when the Fragment is associated with its host Activity.
This is the first lifecycle method called after the Fragment is created.
The onAttach() method receives the Activity as a parameter, allowing the Fragment to interact with its host.
To set a view in the middle in ConstraintLayout, use layout_constraintStart_toStartOf, layout_constraintEnd_toEndOf, layout_constraintTop_toTopOf, and layout_constraintBottom_toBottomOf attributes.
Use layout_constraintStart_toStartOf and layout_constraintEnd_toEndOf to align horizontally in the middle.
Use layout_constraintTop_toTopOf and layout_constraintBottom_toBottomOf to align vertically in the middle.
Set both...
I appeared for an interview in Nov 2024.
The components of an Android app include activities, services, broadcast receivers, and content providers.
Activities: UI components that represent a single screen with a user interface.
Services: Background tasks that run independently of the UI.
Broadcast Receivers: Respond to system-wide broadcast announcements.
Content Providers: Manage a shared set of app data.
Activity is a single focused thing that user can do, while Fragment is a modular section of an activity.
Activity represents a single screen with a user interface, while Fragment represents a behavior or a portion of user interface in an Activity.
An Activity can contain multiple Fragments, but a Fragment cannot exist independently without an Activity.
Fragments have their own lifecycle, while they are dependent on the li...
Databinding is a feature that allows you to bind UI components in your layout to data sources in your app.
Databinding eliminates the need for boilerplate code to update UI components with data.
It allows for easier communication between UI components and data sources.
Databinding can improve code readability and maintainability.
Example: Binding a TextView directly to a ViewModel property in an Android app.
The view is attached to the Fragment during the onAttach() lifecycle event.
The onAttach() method is called when the Fragment is associated with its host Activity.
This is the first lifecycle method called after the Fragment is created.
The onAttach() method receives the Activity as a parameter, allowing the Fragment to interact with its host.
Yes, an activity can exist without a view in Android.
An activity can perform background tasks without displaying any UI elements.
For example, a music player app may have an activity to handle playback controls in the background.
Activities without views are commonly used for tasks like data processing, network operations, or service handling.
A broadcast receiver is an Android component that allows the system to deliver events or messages to the app.
Broadcast receivers can be used to listen for system-wide broadcast announcements, such as when the device is booted or when the battery is low.
They can also be used to receive custom broadcast messages sent by other apps or components within the same app.
Broadcast receivers are registered in the AndroidManifest...
LateInit is used for non-nullable properties that are initialized later, while Lazy is used for properties that are initialized only once when accessed.
LateInit is used for non-nullable properties that are initialized later in the code.
Lazy is used for properties that are initialized only once when accessed, making it suitable for expensive operations.
LateInit properties must be initialized before accessing, while Lazy...
Yes, I have experience working with ViewPager2 and ListAdapter.
Implemented ViewPager2 to create swipeable screens in Android apps.
Utilized ListAdapter to efficiently manage data for RecyclerViews.
Used ListAdapter's DiffUtil to efficiently update RecyclerView items.
Pagination in Android can be achieved by using libraries like Paging Library or implementing custom pagination logic.
Use Paging Library provided by Android Architecture Components
Implement custom pagination logic by loading data in chunks
Update RecyclerView adapter with new data as user scrolls
I have worked on various layouts including linear, relative, grid, and constraint layouts.
Implemented linear layouts to arrange views in a single column or row.
Utilized relative layouts to position views relative to each other.
Used grid layouts for displaying data in a grid-like structure.
Implemented constraint layouts for creating complex and flexible UI designs.
To set a view in the middle in ConstraintLayout, use layout_constraintStart_toStartOf, layout_constraintEnd_toEndOf, layout_constraintTop_toTopOf, and layout_constraintBottom_toBottomOf attributes.
Use layout_constraintStart_toStartOf and layout_constraintEnd_toEndOf to align horizontally in the middle.
Use layout_constraintTop_toTopOf and layout_constraintBottom_toBottomOf to align vertically in the middle.
Set both hori...
A suspend function is a function that can be paused and resumed at a later time without blocking the main thread.
Suspend functions are used in Kotlin coroutines to perform asynchronous operations.
They are defined using the 'suspend' keyword in the function signature.
Suspend functions can only be called from within another suspend function or a coroutine builder like 'launch' or 'async'.
Coroutines in Android can be launched using the 'launch' function from the CoroutineScope.
Use the 'launch' function from the CoroutineScope to start a coroutine.
Specify the context in which the coroutine should run, such as Dispatchers.Main for the main thread.
Handle exceptions within the coroutine using try-catch blocks.
Example: CoroutineScope(Dispatchers.Main).launch { // coroutine code here }
Use runOnUiThread or withContext(Dispatchers.Main) to update UI in coroutine scope.
Use runOnUiThread to update UI from a background thread.
Use withContext(Dispatchers.Main) to switch to the main thread in coroutine scope.
Example: runOnUiThread { textView.text = "Updated text" }
Example: withContext(Dispatchers.Main) { textView.text = "Updated text" }
HashMap is unordered, LinkedHashMap maintains insertion order.
HashMap does not maintain insertion order, LinkedHashMap maintains insertion order.
HashMap allows one null key and multiple null values, LinkedHashMap allows one null key and multiple null values.
HashMap is faster for iteration, LinkedHashMap is slower due to maintaining order.
Syntax for HashMap in Kotlin and Java with values.
In Kotlin:
val hashMap = hashMapOf<String, Int>()
hashMap.put("key1", 1)
hashMap.put("key2", 2)
In Java:
HashMap<String, Integer> hashMap = new HashMap<>();
hashMap.put("key1", 1);
hashMap.put("key2", 2);
Val is immutable, Var is mutable in Kotlin programming language.
Val is used for read-only variables, cannot be reassigned.
Var is used for mutable variables, can be reassigned.
Val is preferred for better code safety and readability.
Example: val name = "John" vs var age = 30
Let and apply are scoped functions in Kotlin used for executing a block of code on an object.
Let function is used to execute a block of code on a non-null object and return the result.
Apply function is used to initialize an object and perform operations on it without explicitly returning a value.
Data can be sent between two activities in Android using Intent with putExtra() method.
Create an Intent object in the sending activity
Use putExtra() method to add data to the Intent
Start the second activity with startActivity() method, passing the Intent
Retrieve the data in the receiving activity using getIntent() and getExtra()
Hot and Cold Flow is a design pattern used in Android development to manage the flow of data between components.
Hot Flow refers to the flow of data that is actively being observed and updated in real-time.
Cold Flow refers to the flow of data that is not actively being observed and updated, but can be retrieved when needed.
Hot Flow is typically used for real-time updates, while Cold Flow is used for fetching data on dem...
RecyclerView is more efficient for displaying large datasets and supports various layout managers, while ListView is simpler and easier to implement.
RecyclerView is more efficient for displaying large datasets as it only creates enough views to fill the screen, while ListView creates all views at once.
RecyclerView supports various layout managers like LinearLayoutManager, GridLayoutManager, and StaggeredGridLayoutManag...
Sealed classes are used to restrict inheritance in Kotlin, allowing a class to have a fixed set of subclasses.
Sealed classes are declared using the 'sealed' keyword.
They can only be extended within the same file where they are declared.
Sealed classes are often used in conjunction with when expressions for exhaustive checking.
Back stack is a stack of activities in Android that keeps track of the navigation history.
Back stack is managed by the Android system to handle the navigation flow of activities.
When a new activity is started, it is pushed onto the back stack.
Pressing the back button pops the top activity off the stack and navigates to the previous activity.
Activities in the back stack can be brought to the foreground by using the appr...
Hashcode is a unique identifier for an object, equals() compares the content of two objects, and == checks if two references point to the same object.
Hashcode is an integer value generated by a hashing algorithm to uniquely identify an object.
equals() method is used to compare the content of two objects for equality.
== operator checks if two references point to the same object in memory.
Example: String class overrides ...
Top trending discussions
I applied via Campus Placement and was interviewed before May 2021. There were 4 interview rounds.
VERBAL QUANT DI/LR and Picture based test
Fibonacci series can be easily implemented using loops in C++ or C.
Declare variables for first two numbers of the series
Use a loop to calculate and print the next number in the series
Repeat the loop until desired number of terms are printed
I appeared for an interview before Sep 2020.
Round duration - 90 minutes
Round difficulty - Easy
This round was held during university hours and consisted of 2 coding questions.
Round duration - 120 minutes
Round difficulty - Easy
Make sure you do no cutting and are clear about the approach you'd be following.
Running median of an input stream is the median value of the numbers seen so far in a continuous stream of data.
Maintain two heaps - a max heap for the lower half of the numbers and a min heap for the upper half.
Keep the number of elements in the two heaps balanced or differ by at most 1.
If the total number of elements is odd, the median is the root of the max heap. If even, it is the average of the roots of the two he...
Prepare for company-wise interview questions according to the company in which you are applying. Try to write the code yourself and if got stuck in between then take help from the internet. I recommend you Codezen of Coding Ninjas for practicing Data Structures and Algorithms based questions.
Application resume tips for other job seekersBe sure 100% of what you write in your resume and prepare for that before the interview what is written on resume.
Final outcome of the interviewSelectedI applied via Referral and was interviewed before Jan 2021. There was 1 interview round.
Abstract class is a class that cannot be instantiated, List is a collection of objects, SQL is a language used to manage databases, ADO.net is a framework for accessing databases.
Abstract class is used as a base class for other classes
List is a generic collection of objects
SQL is used to create, modify, and query databases
ADO.net provides a set of classes for accessing databases
Example: abstract class Animal { public a...
I applied via Company Website and was interviewed before Jan 2021. There were 5 interview rounds.
I applied via Naukri.com and was interviewed in Jul 2020. There were 3 interview rounds.
I'm a passionate software developer with 5 years of experience in building scalable web applications and a strong focus on user experience.
Experience in full-stack development using technologies like React, Node.js, and MongoDB.
Led a team project that improved application performance by 30% through code optimization.
Strong background in Agile methodologies, having participated in multiple sprints and retrospectives.
Dev...
I excel in problem-solving, collaboration, and adaptability, which enhance my effectiveness as a software developer.
Strong problem-solving skills: I enjoy tackling complex coding challenges, like optimizing algorithms for better performance.
Effective collaboration: I have successfully worked in Agile teams, contributing to projects like a web application that improved user engagement.
Adaptability: I quickly learn new t...
I tend to be overly critical of my work, which can slow down my progress and affect my confidence in delivering projects.
I often spend too much time refining code, which can delay project timelines. For example, I once spent an extra week on a feature.
I sometimes struggle with delegation, preferring to handle tasks myself to ensure quality. This was evident in a group project where I took on too much.
I can be hesitant ...
I am looking for a competitive salary that reflects my skills and experience in software development.
Based on my research, the average salary for a software developer in this region is between $80,000 and $100,000.
I have over 5 years of experience in full-stack development, which I believe warrants a salary towards the higher end of that range.
I am open to discussing the entire compensation package, including benefits ...
I applied via Referral and was interviewed before Jun 2021. There were 2 interview rounds.
Java, program logic, software engineering
I applied via Recruitment Consulltant and was interviewed before Aug 2021. There were 2 interview rounds.
I applied via Company Website and was interviewed in May 2021. There were 3 interview rounds.
based on 1 interview experience
Difficulty level
Duration
Software Engineer2
27
salaries
| ₹7 L/yr - ₹17.5 L/yr |
Product Designer
18
salaries
| ₹10 L/yr - ₹12.1 L/yr |
Software Engineer
14
salaries
| ₹7.6 L/yr - ₹14 L/yr |
Senior Software Engineer
12
salaries
| ₹6.3 L/yr - ₹17 L/yr |
Software Developer II
5
salaries
| ₹7.5 L/yr - ₹12 L/yr |
TCS
Accenture
Wipro
Cognizant