programmingknowledgeblog

Python Tutorial for Beginners 16 - Python Dictionary

In this video I am going to show What are Dictionaries and How to use Dictionaries in python. So What are Dictionaries in python?dictionary in python is an associative list or a map.We can think if dictionary as a list of pairs, where the first element of the pair, the key, is used to retrieve the second element, the value.Hence we map a key to a value.Dictionaries are Python’s most powerful data collection. Dictionaries allow us to...

dev.to dev.to

Kotlin Extensions for Minecraft Spigot

Minecraft server MOD Spigot is useful, but there are a few inconvenient methods. Let's change them using Kotlin Extensions. Drop ItemStack You can drop items in the world using the code below, but that is redundant. val location = player.location location.world.dropItem(location, itemStack) Let's create a Location-based method with the following extensions. LocationExtensions.kt fun Location.dropItem(itemStack:...