Skip to content

Instantly share code, notes, and snippets.

David Greenhalgh dgreenhalgh

Block or report user

Report or block dgreenhalgh

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
dgreenhalgh / SimVillage.kt
Created Oct 5, 2018
Big Nerd Ranch Anonymous Functions - SimVillage
View SimVillage.kt
fun main(args: Array<String>) {
fun runSimulation() {
val greetingFunction = configureGreetingFunction()
fun configureGreetingFunction(): (String) -> String {
dgreenhalgh /
Created Oct 4, 2018
Big Nerd Ranch Java Interoperability - Jhava
import kotlin.Unit;
import kotlin.jvm.functions.Function1;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.util.function.Function;
public class Jhava {
dgreenhalgh / Hero.kt
Created Oct 4, 2018
Big Nerd Ranch Java Interoperability
View Hero.kt
fun main(args: Array<String>) {
val adversary = Jhava()
val friendshipLevel = adversary.determineFriendshipLevel()
println(friendshipLevel?.toLowerCase() ?: "It's complicated.")
You can’t perform that action at this time.