Data Classes in kotlinData classes are normal classes mainly created to hold data data keyword is used to mark a class as a data class. data class DataClass(val id:Int, val name: String) Q. why data classes is used to hold data ? or what is the difference between it and...2 min read·mohamedewida.hashnode.devFeb 9, 2023
Abstract classes vs Interfaces in KotlinAs you may know, interfaces are just abstract functions but with subtle differences. Abstract means two things : this class can’t be instantiated this class can have fields with no implementation (abstract fields like abstract functions or abstract...2 min read·mohamedewida.hashnode.devFeb 9, 2023