Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


How to declare variable in Kotlin ?



How to declare variable in Kotlin ?..

Answer / Gyanendra Kumar Singh

To declare a variable in Kotlin, you should use the 'var' keyword for mutable variables and the 'val' keyword for immutable (constant) variables. For example: var name: String = "John", val AGE: Int = 25

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Kotlin Interview Questions

What is Range in Kotlin?

1 Answers  


How can you handle null exceptions in Kotlin?

1 Answers  


Describe the use of extension function?

1 Answers  


What are High-Level Functions in Kotlin?

1 Answers  


Define enum in Kotlin?

1 Answers  


What are the advantage of using Kotlin ?

1 Answers  


Can you execute Kotlin code without JVM?

1 Answers  


What are the major features of Kotlin?

1 Answers  


Does Kotlin support Checked Exceptions like in Java?

1 Answers  


List of extension methods kotlin provides to java.io.file?

1 Answers  


Who created Kotlin programming language and when?

1 Answers  


What are the disadvantages of kotlin?

1 Answers  


Categories