This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
override fun onStop() { | |
super.onStop() | |
releasePlayer() | |
} | |
override fun onPause() { | |
super.onPause() | |
releasePlayer() | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class MainActivity : Activity() { | |
private lateinit var binding: ActivityMainBinding | |
private var exoPlayer: ExoPlayer? = null | |
private var playbackPosition = 0L | |
private var playWhenReady = true | |
override fun onCreate(savedInstanceState: Bundle?) { | |
super.onCreate(savedInstanceState) | |
binding = ActivityMainBinding.inflate(layoutInflater) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" | |
xmlns:app="http://schemas.android.com/apk/res-auto" | |
xmlns:argType="http://schemas.android.com/tools" | |
android:id="@+id/flRoot" | |
android:layout_width="match_parent" | |
android:layout_height="match_parent" | |
android:focusable="true" | |
android:keepScreenOn="true"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
val programmingLanguages = ArrayList<String>() | |
programmingLanguages.add("Kotlin") | |
programmingLanguages.add("Swift") | |
programmingLanguages.add("Java") | |
programmingLanguages.add("Objective-C") | |
val studentNames = ArrayList<String>() | |
println(studentNames.contains("Java")) | |
println(programmingLanguages.contains("Java")) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
val programmingLanguages = ArrayList<String>() | |
programmingLanguages.add("Kotlin") | |
programmingLanguages.add("Swift") | |
programmingLanguages.add("Java") | |
programmingLanguages.add("Objective-C") | |
val studentNames = ArrayList<String>() | |
println(studentNames.isEmpty()) | |
println(programmingLanguages.isEmpty()) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
val studentNames = ArrayList<String>() | |
programmingLanguages.add("Halil") | |
programmingLanguages.add("Ibrahim") | |
programmingLanguages.add("Yusuf") | |
programmingLanguages.add("Efe") | |
studentNames.clear() | |
println(studentNames) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
val programmingLanguages = ArrayList<String>() | |
programmingLanguages.add("Kotlin") | |
programmingLanguages.add("Swift") | |
programmingLanguages.add("Java") | |
programmingLanguages.add("Objective-C") | |
val studentNames = ArrayList<String>() | |
programmingLanguages.add("Halil") | |
programmingLanguages.add("Ibrahim") | |
programmingLanguages.add("Yusuf") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
val programmingLanguages = ArrayList<String>() | |
programmingLanguages.add("Kotlin") | |
programmingLanguages.add("Swift") | |
programmingLanguages.add("Java") | |
programmingLanguages.add("Objective-C") | |
println("Programming Languages: ${programmingLanguages.size}") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
footballTeam.remove("Trabzonspor") | |
footballTeam.removeAt(2) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
println(footballTeam.get(0)) | |
println(footballTeam[2]) |