Q&As
What is an inline function in Kotlin?
In Kotlin, the higher-order functions or lambda expressions, all stored as an object so memory allocation, for both function objects and classes, and virtual calls might introduce runtime overhead. Sometimes we can eliminate the memory overhead by inlining the lambda expression.
What is the difference between var and val in Kotlin?
In Kotlin, var is used to declare mutable variables, which can be reassigned after initialization. val, on the other hand, is used for immutable variables, meaning their value cannot be changed once assigned.
What are widgets in Flutter?
Widgets are the basic building blocks of a Flutter app's user interface. Each widget is an immutable declaration of part of the user interface. Flutter widgets include structural elements like buttons, layout components, and stylistic details.
What is State Management in Flutter?
State management is to manage and share app's state (data) across different parts of an application. In Flutter, there are several approaches: Provider, Bloc, Riverpod, setState, etc.