Skip to content
This repository has been archived by the owner on Mar 25, 2024. It is now read-only.

A small improvement on the readability of the code. #16

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions app/src/main/java/com/example/wordsapp/LetterAdapter.kt
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,7 @@ class LetterAdapter :
val button = view.findViewById<Button>(R.id.button_item)
}

override fun getItemCount(): Int {
return list.size
}
override fun getItemCount(): Int = list.size

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's possible to improve even more, what do you think about that?

Suggested change
override fun getItemCount(): Int = list.size
override fun getItemCount() = list.size


/**
* Creates new views with R.layout.item_view as its template
Expand Down