In Java and Kotlin, I usually create literal arrays with each item on a new line and all columns lined up nicely. To add a new item, I can then just copy any line and change what I need. To edit all items at once I just add a carat at the beginning of each line and off I go.
EXCEPT FOR THE LAST LINE WHICH DOESN'T HAVE A COMMA.
valitems=arrayOf(Item(1,"One",1.1),Item(2,"Two",2.2),Item(3,"Three",3.3),Item(4,"Four",4.4),Item(5,"Five",5.5)// <-- I want to put a comma here so badly!)
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
In Java and Kotlin, I usually create literal arrays with each item on a new line and all columns lined up nicely. To add a new item, I can then just copy any line and change what I need. To edit all items at once I just add a carat at the beginning of each line and off I go.
EXCEPT FOR THE LAST LINE WHICH DOESN'T HAVE A COMMA.