Mind the GeekMind the Geek
Conference50min
BEGINNER

Snake in 10 Lines: Learning More by Coding Less

Can you create a complete game with just 10 lines of code? That was the quest I set myself when recreating the classic game Snake in as few lines as possible. Let me tell you: I was not ready for the types of challenges I would face. For example, just registering button presses was not as straightforward as I had hoped. Through live coding, I will show you how I overcame these obstacles and distilled Snake to its absolute essence. What key elements make this game instantly recognizable? By combining Kotlin and Swing, we will end up with a minimal code base and if not award-winning, at least a playable version of Snake. Striving for conciseness led me to a deeper understanding of the code. I will show how constraints push us to think outside the box and lead to more creative solutions. Moreover, my approach can be applied to any problem. Sometimes the best way to understand code is by seeing how little of it you actually need!

talk.summaryAiDisclaimer

Guus de Wit
Guus de Witadesso Netherlands

talkDetail.whenAndWhere

Friday, June 19, 11:40-12:30
Room 4A
talks.description
Can you create a complete game with just 10 lines of code? That was the quest I set myself when recreating the classic game Snake in as few lines as possible. Let me tell you: I was not ready for the types of challenges I would face. For example, just registering button presses was not as straightforward as I had hoped.

Through live coding, I will show you how I overcame these obstacles and distilled Snake to its absolute essence. What key elements make this game instantly recognizable? By combining Kotlin and Swing, we will end up with a minimal code base and if not award-winning, at least a playable version of Snake.

Striving for conciseness led me to a deeper understanding of the code. I will show how constraints push us to think outside the box and lead to more creative solutions. Moreover, my approach can be applied to any problem. Sometimes the best way to understand code is by seeing how little of it you actually need!
creativity
snake
kotlin
minimalism
talks.speakers
Guus de Wit

Guus de Wit

adesso Netherlands

Netherlands

Guus is a Java/Kotlin developer at adesso Netherlands. With a passion for puzzles and a background in science, he strives for elegant solutions to complex problems. In his spare time, he likes to over-optimize the simple tasks of today, to hopefully live a lazy life tomorrow