
I do want it to be possible to put a String and an Int into this list, at the same time.

I'm not looking to support other objects. Syntax of List.size () The syntax of List.size property is list.size Return Value List.size returns the size of list as integer. The Kotlin List.size property returns an integer representing the size of the list. I only want to have Any be a String or a primitive. Kotlin List size To get the size of List in Kotlin, read size property of List object. The elements that will be in this list are arguments for functions I will be calling. The args parameter is for a list of 'Any?'. But, I haven't found anything in the documentation, or any examples elsewhere, that look useful for what I'm trying to do. To use context serializer as fallback, explicitly annotate type or property with googled that I probably have to write a custom serializer and deserializer for this use case. IntelliJ gives me a red line on the 'Any?', and it says Serializer has not been found for type 'Any?'. This doesn't seem to work by default with Kotlin Serialization. I have a class that looks like this, class M圜lass(

And, List in Kotlin is an interface that extends the Collection interface. It's been pretty nice, but I've run into a pain point. List in Kotlin A list is a generic ordered collection of elements that can contain duplicate values.

I'm migrating a project from Gson to Kotlin Serialization.
