u/loehnertz
-
18points
- 13points
-
7points
I created a sorting puzzle where you need to figure out the metric to sort by (i.redd.it) [[PC] (Web)]
-
55points
-
3points
-
7points
-
1points
-
0points
loehnertz
loehnertz
Oh, thanks so much for this comment. This warms my heart to see that you took the time to write this!
Other people already pointed out the "reverse order" issue. I think I need to implement something at least so that when someone has everything right, it counts, or so.
I will keep creating and releasing new ones. Feel free to "install" it to your computer or phone (it's just a website still) and turn on push notifications for new puzzles.
Thanks again :)
loehnertz
Then I did something right 😄
loehnertz
Thanks a lot, very happy to hear :)
loehnertz
Thank you :)
loehnertz
Thanks for the feedback!
It's definitely inspired by the NYT Games (and "Connections" in particular).
I got this feedback point also from other people, so thanks for confirming that I need to implement something about that.
loehnertz
What makes it kinda ass?
loehnertz
Thanks for your feedback!
It's not reaaaally time-based in that sense. Yes, the time you took is used to calculate the "Skill", but it's only a tiny fraction of the formula.
So if you really want to get a good "Skill" score, needing fewer attempts and no assists will be rewarded.
loehnertz
Thanks! I also thought that sound effects would make this game more polished. I'm happy to hear you like them.
loehnertz
Spectra – A daily sorting puzzle where the metric to sort by is hidden
Link: https://spectra.quest/
The Concept: You are given a list of items (e.g., countries, animals, movies, languages), and you have to sort them. The catch? The game doesn't tell you how to sort them. Multiple metrics could be used to sort the items, so you must figure out which is being used by analyzing the feedback provided after each guess. Unlike other puzzle games, researching is explicitly allowed (but not required).
I had this idea some time ago and implemented it as a purely web-based, free, ads-free, no-login site, as I wanted to create a puzzle game that rewarded research skills.
Features:
- Daily new puzzle
- Different modes to make it easier or harder
- Community Stats
- Leaderboards (global and groups)
- and more…
➡️ Check it out and give me feedback!
I’m especially curious about:
- Did the goal make sense within ~10 seconds?
- Did you get an actual “aha” moment?
loehnertz
I think music is always nice, especially if there are "just" graphics.
Firstly, I agree that it's too loud. I also personally think that something ambient and roomy would be best also for the visual style, it would feel a bit more dark and mysterious. Also personally, the biggest issue with the current music are the BPM. It's too fast (for me), I do actually like the track itself a lot but it makes my brain race to much although one has to highly concentrate on the content. The other downside this brings is that it makes a confusion between the video cuts and the beat of the track. I noticed you cut it to the beat, so that already alleviates that but the track's drums are still very popping. Although the fact that it's upbeat, I like, I wouldn't make it dark in the sense of sad music.
Although in episode 2 on the channel itself, it generally checks those boxes. Also, in case you don't already, make sure to EQ the background music with an inverted EQ of your voice track, otherwise it clashes in some frequencies. It's hard to tell if you already do, so just ignore it in that case.
I think something quieter, slower, while still upbeat, I'd like the most to watch the videos. Something in the general style of "Air - La Femme D'Argent" is a nice style – so Electronica (not to be confused with just any electronic music). Actually, that specific piece has way too many solos and improvisation for background music in a video, would distract from the contents. But you get the general idea, something spacious, soothing would fit your content very well. Additionally, look into Downtempo or IDM, although that latter term is very convoluted. Might be a subjective thing though of course! Finally, I think these genres have many pieces that are generally appealing. The piece by Air above for instance, I'd argue no one "hates". Additionally, your visual style might also benefit from Synthwave although that precisely has the issue I mentioned above, it's potentially not compatible enough with a general audience while it ticks all the other boxes I mentioned. Finally, I'd actually argue that classic Smooth Jazz or the quieter pieces of Fusion Jazz would also work pretty nicely with the style and content.
Just my personal thoughts of course. Hope this helps :)
Btw, did you reach almost 400 subscribers just via this post? :D
loehnertz
This is so cool! Running an educational YT channel on software development myself, I really appreciate the production quality and even more so considering you created the channel only this week. Your videos will make it big, I feel. This should be super helpful to many people in our space. Subscribed and looking forward to what you'll release!
If you want more feedback or anything, let me know :)
loehnertz
Good point, will look into it for a potential follow-up video! It's hard though as the font size of the code will likely become borderline too small – valid criticism nonetheless :)
loehnertz
In Part 1, I spotted a nice property: If one takes the arithmetic mean of a column, if the value is > 0.5, the 1 was more common and vice versa. That together with transposing the input as a matrix, makes for very lean code!
Kotlin:
fun solvePart1(input: String): Any {
val rows: List<List<Int>> = input.splitMultiline().map { it.toBitString() }
val mostCommonBits: List<Int> = rows.transpose().map { if (it.average() > 0.5) 1 else 0 }
val leastCommonBits: List<Int> = mostCommonBits.map { it.bitFlip() }
val gammaRate: Int = mostCommonBits.binaryToDecimal()
val epsilonRate: Int = leastCommonBits.binaryToDecimal()
return gammaRate * epsilonRate
}
fun String.splitMultiline(): List<String> = split("\n")
fun List<Int>.binaryToDecimal(): Int {
require(this.all { it == 0 || it == 1 }) { "Expected bit string, but received $this" }
return Integer.parseInt(this.joinToString(""), 2)
}
fun Int.bitFlip(): Int {
require(this == 0 || this == 1) { "Expected bit, but received $this" }
return this.xor(1)
}
fun String.toBitString(): List<Int> {
val bits: List<String> = split("").filter { it.isNotBlank() }
require(bits.all { it == "0" || it == "1" }) { "Expected bit string, but received $this" }
return bits.map { it.toInt() }
}
/**
* [Transposes](https://en.wikipedia.org/wiki/Transpose) the given list of nested lists (a matrix, in essence).
*
* This function is adapted from this [post](https://stackoverflow.com/a/66401340).
*/
fun <T> List<List<T>>.transpose(): List<List<T>> {
val result: MutableList<MutableList<T>> = (this.first().indices).map { mutableListOf<T>() }.toMutableList()
this.forEach { columns -> result.zip(columns).forEach { (rows, cell) -> rows.add(cell) } }
return result
}
loehnertz
If you are already proficient in Java, I think these puzzles are actually quite cool to learn Kotlin. You can always start out by thinking about how you would do it in Java and then Google around a bit or check other people's solutions, how it's nicely done in Kotlin. With that, I think you'll be up to speed in terms of the baseline of Kotlin quite quickly.
The puzzles indeed are a bit "fluffy", but it's no different than math assignments back in school, I'd say, where one only really requires 50% of the text and part of the skill is to extract information.
loehnertz
Really nice, always a very nice time of the year for developers around the globe 🎄
I'll attempt to record me solving all the puzzles with Kotlin this year. You'll find the playlist here: https://www.youtube.com/playlist?list=PLo7x9g_4b5xKlnlod-Ywos_6Vq3R7c8Qd
I'll also make sure to publish the code written in each episode over here: https://github.com/The-Self-Taught-Software-Engineer/advent-of-code-2021
Let's get in touch, if you participate this year as well :)
loehnertz
Funny, I had the exact same idea of this meme for the thumbnail of a video I recently produced about this topic: https://youtu.be/eCnJW2n0vCA
Thanks so much for this comment and that you took the time to write it – that means a lot!!
You're making good points, that's also what I like when designing the puzzles 😄
Feel free to activate the push notifcations, if you want to keep playing new puzzles and be notified when they release.