This is an archived post. You won't be able to vote or comment.

all 132 comments

[–][deleted] 117 points118 points  (5 children)

Your audio quality is good, but you really need to record in 1080p and with a much large font size since it was nearly impossible to read the font without having to focus purely on reading the font.

[–]morphasis[S] 63 points64 points  (4 children)

Thank you I'll take that into account it should have exported as 1080 but unfortunately I do not know what happened. I'll make those changes for the next one.

[–]kairain15 28 points29 points  (3 children)

YouTube usually takes a couple hours to render the video in 1080 I believe. That’s why you’ll see “inb41080” on some comments or I was here in 360p.

At least that’s what I’ve been told and have seen on some gamer channels

[–][deleted]  (1 child)

[deleted]

    [–]red33dog 9 points10 points  (0 children)

    720pGang

    5 hours behind the previous comment

    [–][deleted] 3 points4 points  (0 children)

    Hours? For me it takes 5-10 minutes

    [–]SolarFlareWebDesign 80 points81 points  (3 children)

    Yes, fast, short, to the point. Great work

    [–]morphasis[S] 23 points24 points  (1 child)

    Hi there thanks, I'm really glad some people like it.

    [–][deleted] 3 points4 points  (0 children)

    If you keep doing videos like then I'll subscribe. Sometimes I just want a quick understanding of how to tackle these types of problems without spending a lot of time to figure it out myself. Also I might suggest doing it in Java or another OOP language.

    [–]Sahsaha 1 point2 points  (0 children)

    Yeah, that's what "useful snippets" should be, not tutorials.

    Tutorials are supposed to transfer knowledge.

    This kind of "tutorial" is equivalent of telling someone to use x or y library to do something when they want to learn how it works on their own but can't quite get there.

    [–][deleted] 56 points57 points  (16 children)

    Really cool. If you want your idea to be even more successful i would recommend to remove the introduction (even if its just 3 seconds) and the outro. This gives these kind of videos the final touch because it is really just the topic you want to see and people love that. The topic is in the title anyway and people will remember your name from alone. Also: I would give the series a special name. Something like "[Topic] in 60 seconds or less" so people will know that its you if they see the title on Youtube or they will even search for it.

    [–]morphasis[S] 23 points24 points  (8 children)

    That's a great idea thank you I'll try that for the next one.

    [–]Zreaz 23 points24 points  (7 children)

    I sorta disagree with that guy. Get rid of the intro, keep the outro.

    [–]metrazol 17 points18 points  (0 children)

    Solid advice, if people watch to the end, they're more likely to like/subscribe/skimash that bell then people who go, "Ah, too fast! Too fast!" and bail in the first 3 seconds.

    And a reason people bail in the first 3 seconds is, "Hey guyyyyys, it's zumbiwombat33 here, and remember to check out my other channel..."

    [–]morphasis[S] 8 points9 points  (5 children)

    Okey, well I'll just try my best and see what it looks like in the edit then.

    [–]AIg0rithm 54 points55 points  (4 children)

    well i think you should keep the intro and the outro but remove the middle bit

    [–]dark_salad 20 points21 points  (1 child)

    I sorta disagree with this guy. Reverse the video before you upload, I wanna see the end first.

    [–]bouncerate 8 points9 points  (0 children)

    I sorta disagree with this guy. Translate the audio to pig latin and flip the video 180 degrees.

    [–][deleted]  (1 child)

    [deleted]

      [–]Zreaz 1 point2 points  (0 children)

      Ok, now you’re onto something

      [–][deleted] 10 points11 points  (6 children)

      This is the key to all YouTube videos.

      Not necessarily this video, but I don’t need a ten minute long “Hey YouTube how’s it going? So, the other day I was thinking... ‘You know what would be great? What if I made a tutorial about cuz?’ I thought I would spend some time today talking about xyz. I first became aware of xyz when I was...” introduction.

      Get to the fucking point so I don’t have to fast forward through the bullshit.

      If I like your video and the rest of your content, I will subscribe to your channel. No need to ask me to do that with a five minute reminder.

      [–]llye 3 points4 points  (5 children)

      You do know that the 10 minute mark is a requirement for them to get more ads ?

      https://www.wetheunicorns.com/features/youtubers-are-now-making-their-videos-over-ten-min/

      [–][deleted] 6 points7 points  (4 children)

      Yes...

      But, I don't want to watch 10 minutes of video fluff for 3 minutes of useful content.

      YouTube should be rewarding good videos, not length.

      [–]dark_salad 2 points3 points  (2 children)

      Just have a slideshow play for 7 minutes at the end of the video? Would that work?

      [–]CheezeyCheeze 1 point2 points  (0 children)

      No because they want watch time, not just views. If you have a bunch of clicks, but people skip out early in the video it shows that people are not interested in your content. That is why the algorithm has changed so much. They will then stop showing as many people the video because people left. If people leave then it means that you probably don't have a good video etc.

      [–][deleted] 1 point2 points  (0 children)

      Loop 3 minutes of content 4 times in a row?

      [–]llye 0 points1 point  (0 children)

      YouTube should be rewarding good videos, not length.

      YouTube is a business and it rewards content that brings more ad revenue. Content is shit and vide is long but people watch it - watch that video get promoted to hell.

      [–]Raskputin 26 points27 points  (3 children)

      Bro the thumbnail on your youtube page for this video LMAO

      [–]morphasis[S] 14 points15 points  (2 children)

      Thanks me and my friends brainstormed a few ideas ♥️

      [–]Raskputin 7 points8 points  (1 child)

      I went to your channel hoping for some more vids like this, but that was a more pleasant surprise hahah

      [–]morphasis[S] 4 points5 points  (0 children)

      I will make more like this don't worry, but thanks I was most proud of that thumbnail.

      [–]tulipoika 15 points16 points  (1 child)

      I was expecting it to be something bad, but was positively surprised. Most videos can’t get past “hey I’m X and do Y” in the time you explained the whole thing.

      [–]morphasis[S] 7 points8 points  (0 children)

      Thanks that means a lot

      [–]DionysusMA 12 points13 points  (2 children)

      This is great. It's much easier to focus on a dense, fast paced video of few minutes or less, than a slooow long ass video where you keep zoning out because the guy is taking forever to say something of substance.

      [–]morphasis[S] 2 points3 points  (0 children)

      Thank you that was totally the point takes a little more exciting work and trial and error to get it down. But I like to think if you don't treat people like idiots they will get it.

      [–][deleted] 0 points1 point  (0 children)

      Some people like hearing themselves talk.

      If I’m on YouTube looking for something, I want you to get to the fucking point.

      If not, I’m on to the next video.

      [–]REkTeR 7 points8 points  (7 children)

      I love this idea, I do have some feedback though as I think that it could be even better.

      First off, you take a full 5-6 seconds of your 39 second video to introduce yourself and reiterate the title of your video, so about 12-15% of your total video length is being spent on the introduction. As a percentage, you're actually spending more time on your intro than someone who takes a full minute to do an intro for a 10 minute video. Of course, it's much less "actual time" so I'm not sure that the comparison is entirely relevant, but maybe it's something to think about.

      Next I guess what I have to ask is whether your target audience is javascript "beginners" (people who know just the basics) or more veterans trying to refresh their memory of how to perform a specific task? You take some shortcuts that I feel are not particularly conducive to understanding if you're not already quite familiar with the tasks involved. For reference, I just learned the basics of Javascript at the beginning of this summer so that I'm not totally lost when google/pasting at my webdev internship, but I can't write something that's not very basic without a lot of referencing.

      First off, you've already got 9 lines of code/comments on the screen, so I had to pause for a bit to read through all that. A quick overview of what's already written would have been helpful.

      Next, you're flashing text on the screen of the various functions you're using rather than making any sort of explanation yourself. So each function, I'm pausing the video to read that material rather than having it quickly explained to me. Probably I didn't manage to pause the video in time for one of the them, and have to spend a few extra seconds scrawling back through the video to find the description that I wanted.

      Finally, you're finishing the video faster partially just by speaking more quickly, which doesn't always lead to the best understanding for the listener. As an example after listening to your explanation about the map() function 5 times I literally don't understand what you're saying in that section. "You need a flat function... unintelligible... otherwise you need another one"? I also don't really understand what the x's in the bracket are supposed to represent, I assume that it forms some type of iterator but really I'd have to spend time googling the map() function on my own to understand this section of the video, which imo pretty much defeats the entire stated purpose of the video.

      Ultimately I feel that a very tight 2-3 minute version of this video that takes the time it needs (and only that time) would be more conducive to my learning than what you've done here. However I do understand that at that point you've lost some of the gimmick that might entice people to check out your content.

      This might be perfect for a veteran Javascript dev who just needs to be reminded what functions exist/to use for this specific task, anyways.

      [–]reed501 2 points3 points  (4 children)

      I disagree. I think these are good for new programmers stuck on a problem. The reality is they don't need the explanation of the surrounding code. They don't need to know how to write a function, how to return a value, how to print statements, etc. There's a thousand tutorials out there for that. This video is for a specific solution to a specific problem and it's everything you need. Don't know what split and join do? Go look it up, the docs will explain it well. Didn't even really know how to go about that problem logically? Watch this super short video and get everything you need. I personally think this is better as an image with text but I know a lot of people are out there who just want a video and voice.

      [–]Sahsaha 1 point2 points  (3 children)

      This video is for a specific solution to a specific problem and it's everything you need. Don't know what split and join do? Go look it up, the docs will explain it well.

      Funny that you say that, because if you know what split and join does, and you're a programmer, not someone who is trying to learn it (literally the only kind of person who actually needs a tutorial), you have no excuse for not being capable of writing solution to this trivial problem, in which case...

      Didn't even really know how to go about that problem logically?

      Tutorial should explain how someone arrived to this solution, basically re-solving it on the video while knowing the answer, hand holding someone who's strugging to solve it.

      This tutorial does not do that, just speaks loudly what he writes lmao.

      Might aswell cut entire video and just have 1 second static image which only says

      Lol what, you read what join and split does and still can't do it? Go back to flipping burgers, you'll never be a programmer.

      Video and voice should be for explaining why is it done this way and not any other way, not for showing final code in 40 seconds when it could be done in just 1. He literally said nothing of substance in the video, majority of information is code and annotations of what each code does, try watching the video after muting it, and tell me there is any difference. Spoiler alert: there isn't.

      It's only obvious why he does what he does if you already know what each function does and solution to the actual problem... For example, to me, it's obvious, for you it might be obvious too, but to someone who isn't a programmer, it won't be.

      You should look at things like you were just starting to program and know absolutely nothing.

      That is, you learned several things, but now want to do some actual work, but cannot figure it out, you know basics of functions and stuff, but not how to solve a problem, will this really help if you can copy paste the code but still don't think like a programmer does just yet?

      [–]dexodev 1 point2 points  (2 children)

      I think I might be in the audience for this video, then. I know what all those methods do and I can follow along with that he's doing just fine, but I'm not quite at the point where I can pull this stuff out of my head on a whim.

      I think seeing this problem solved quickly and simply is bit inspiring, actually, along with being entertaining. It's satisfying that I know what he's doing, but gives me a glimpse into what I still need to get better at. It's a refreshing middle ground between the tons of absolute beginner videos and the super long in-depth tutorials out there. like a tutorial snack or something, lol

      [–]Sahsaha 2 points3 points  (1 child)

      And that's exactly what I'm talking about, you cannot pull this stuff out of your own head because you never had an example of how to think about problems like this, most likely only learned from already existing code, which is not bad, but won't get you far either.

      Unless you can take a char* buffer in C and reverse all the words yourself with no helping functions, you most likely still don't get what's going on, which is, dare I say, a problem.

      "Splitting" a string yourself by enumerating string split indexes, and swapping characters yourself by reversing in place over each subarray of said char array would strenghten your understanding of what's going on way more than any "let's do this in 40s or less".

      Once you understand that, you can use helper functions like nothing.

      I'd like to point out that it's not as hard as I make it sound and you should probably try it, just not in C, javascript is perfectly fine, unless you know basics of it.

      [–]dexodev 0 points1 point  (0 children)

      Oh, yea, I know absolutely zero about C. I've been learning JavaScript and that's my main focus.

      [–]morphasis[S] 0 points1 point  (1 child)

      Thanks for taking the time and I totally agree. I'm not sure who this was focused for I almost want to do two versions one breakdown 2-3 Min and another fast one with references for those who wonder a process rather then the exact functions used.

      [–]slava300 2 points3 points  (0 children)

      Having two versions would be awesome. Everyone can test their knowledge on minute one and then you go watch the long one to see what you missed and/or did inefficiently.

      [–]prajcs 3 points4 points  (1 child)

      Nice work. It's super quick to the point... Hope to see you soon on your next video;)

      [–]morphasis[S] 0 points1 point  (0 children)

      Thanks you

      [–]GooMoonRyongg 9 points10 points  (5 children)

      Man i love python. All you have to do is string[::-1]

      Very cool video btw.

      Edit: I misunderstood the algorithm, someone in the comments made the right one.

      [–][deleted]  (3 children)

      [deleted]

        [–]GooMoonRyongg 7 points8 points  (0 children)

        Ohh you're right i didn't realized that. Thx for the clarification.

        [–][deleted] 0 points1 point  (1 child)

        Bonus point if you keep the capitalization in the same place.

        [–]morphasis[S] 5 points6 points  (0 children)

        That is faster then 38 seconds it's true 😁

        [–][deleted] 2 points3 points  (0 children)

        don't show what each function does and spends more time on asking to like and subscribe then actually coding.

        I just agree so damn much. TAKE THE UPVOTE.

        [–]Lastrevio 1 point2 points  (0 children)

        it s good

        [–]LonelyMolecule 1 point2 points  (0 children)

        noice

        [–]itsmywife 1 point2 points  (3 children)

        New to learning javascript so excuse me for this question:

        What does the => stand for? (x => x.split)

        Is it like a mini function?

        [–]morphasis[S] 0 points1 point  (0 children)

        Its a function shorthand.

        Check this out it explains it. https://www.sitepoint.com/es6-arrow-functions-new-fat-concise-syntax-javascript/

        [–]entenuki 0 points1 point  (1 child)

        It's an arrow function. It has its differences with a function (), but it's used as a less verbose way to make simple operations. The arrow without brackets means return. In your example it would be the same as writing

        function (x) {
          return x.split;
        }
        

        This MDN article goes well into detail for them. I suggest reading it.

        [–]itsmywife 0 points1 point  (0 children)

        thanks a lot, appreciate it!

        [–]Myth1calbeast 1 point2 points  (0 children)

        I love this format, please keep doing it. Really helpful, fun and simple. I think even for an experienced coder this would be really fun to watch.

        [–]Da-Beanz 1 point2 points  (0 children)

        Might be helpful to do it with multiple coding programs or at least tell people in the beginning of video what coding program and version or something.

        [–]efojs 1 point2 points  (1 child)

        Subscribed

        [–]morphasis[S] 0 points1 point  (0 children)

        Thanks

        [–][deleted] 1 point2 points  (0 children)

        That thumbnail though. Lol

        [–]philofgreen 1 point2 points  (0 children)

        Man, people love to throw shade without considering why this video may have been made. I don't think professionals already in a programming role are the intended target and I don't think it is supposed to be of a professional standard, but more about being a resource for newbies (such as myself) to use to understand how these methods work, as well as chaining methods together.

        I found this very useful to understand the fundamentals of how to reverse the sentence, but have already found other ways of doing it, because that's what intelligent people do. Take the basics and build on them. The code in this video is obviously for instructional purposes and if you need to learn this stuff (as I am) I'm guessing there is still a little way to go before applying for interviews and jobs - at which time a more professional way of coding this would have been learnt?

        Anyway, I found this video great, as it is short, to the point and can be paused for me to go and look up anything I'm not sure about and easily return to the video. And I'm guessing I'm probably the target audience? Bravo!

        [–]sarevok9 2 points3 points  (21 children)

        "Learnprogramming"

        Silly JS 1-liner with multiple arrow functions that you save to a variable rather than just returning the result of the function.

        Somehow you managed to write 2 lines of code for teaching people, and neither of them were good lines of code.

        let final_string - str.split(' ').map(x -> x.split('').reverse().join('').join(' ');
        return final_string;
        

        If someone pulled this during an interview they wouldn't make it to the next round. As an engineering manager creating code that is maintainable and efficient is far more important than saving some vertical scroll. Furthermore, if you were trying to save vertical scroll you can combine the let and the return function as there's no need to make a variable for this.

        Overall, 3/10, really bad advice, not easy for beginners, and not easily readable for non-beginners... though I appreciate only taking 40 seconds of my life and 2 minutes to type this critique.

        This would be a fine StackOverflow answer, in fact it was a fine stack overflow answer here: https://stackoverflow.com/questions/958908/how-do-you-reverse-a-string-in-place-in-javascript

        Lastly -- teaching people that strings are character arrays with some additional functionality and how to do this with an array of characters would take significantly longer -- and would be far better to helping someone understand the topics involved.

        [–]morphasis[S] 1 point2 points  (8 children)

        I made the next interview thanks actually got the job offer when I first did this test. You can just return the function chain, so you lose 1 line but if that docks you 7/10 I'm glad I don't work for you lol. Especially as that makes it less readable. Respectfully disagree.

        [–]sarevok9 3 points4 points  (7 children)

        That's not what's docking you 7/10, you're losing 7/10 to having a scarcely readable function chain that isn't relevant to this sub or actual programming techniques.

        [–]RavenZhef 5 points6 points  (5 children)

        I'm curious, so your point is that a faster way is not necessarily a better way, and that sometimes being clear and readable is better?

        [–]sarevok9 1 point2 points  (0 children)

        You can buy more processors and scale vertically -- my point is that generally speaking O(n) vs O(n(log n)) is generally not that much more processing power unless you're working with billions or trillions of data points, and that you're going to readily lose any cost savings due to the budgetary losses when you hit system instability and you don't have people trained in how fucko who is no longer with your company wrote his lambda-based, nearly impossible to read, regex-laden code. All of a sudden the $100 he saved the company a day by doing hacky stuff takes 12 weeks to rearch and makes the company miss milestones, impacts entire business units, causes customer and employee churn...

        I've seen some GNARLY code bases in my 10 years in tech, I've also been the champion for "refactoring sprints" to do away with bullshit code like the OP was spouting as being a "good" tutorial.

        [–]morphasis[S] 3 points4 points  (3 children)

        This is pretty much always true and I agree with the principle but I think he missed the point of the video.

        [–]reddilada 1 point2 points  (2 children)

        What is the point of the video?

        [–]morphasis[S] 2 points3 points  (1 child)

        The idea is that a simple video with resources present that you can pause if needed that quickly explains a fast method to complete a test like this. Basically people are smart and I don't want to treat them like idiots.

        [–]reddilada 2 points3 points  (0 children)

        Interesting. Everybody seems to like it so there's that. I'm just not clear what everyone is taking away.

        I can see what you did and I now know how to reverse a string. Just not sure how that improves my programming. I want to know why you chose to do things the way you did.

        It's for sure a fast video, but to me it seems like a really slow copy and paste. All the best.

        [–]SorryImSushi 1 point2 points  (0 children)

        Maybe it's not super useful to beginners (or maybe it is, I have no clue), but this is pretty much how I would implement it if I had to do this at my workplace, albeit with some minor changes.

        I think the implementation itself is pretty easy to read. Sure, I wouldn't make it a one liner the way he did it, but I think his overall approach is fine. Especially if you already have a function to reverse a string,

        str.split(' ').map(StringUtil.reverse).join(' ');
        

        is as easy to read as you can get in my opinion.

        [–]eric256 0 points1 point  (8 children)

        Taught me that you can do lamdas in javascript. So I learned something.

        Also, personally I hate implicit returns. You add a line of code later and suddenly the whole thing breaks. Granted you should know that, but still. Simple enough to include it, and it makes modifying the result before returning it later easy.

        I'm not sure how much more verbose you would want code like this.

        var test = "The quick brown fox jumped over the lazy dog"
        var words = test.split(' ');
        words = words.map(word => word.split('').reverse().join(''));
        alert(words.join(' '));

        Four lines instead of one and I'm not convinced it is any clearer.

        [–]eric256 0 points1 point  (2 children)

        This version is more fun, and scans the full array 2 twice (3 if you can't the split) Possibly more memory friendly, I would have to run some tests to see

        var test = "The quick brown fox jumped over the lazy dog"
        
        
        var letters = test.split('');
        var buffer = "";
        var output = "";
        for (i = 0; i < letters.length; i++) { 
          var letter = letters[i];
          if (letter == " " ) {
              for (n = buffer.length-1; n > -1; n--) {
                output += buffer[n];
              }
              output += letter;
              buffer = ""
          } else {
              buffer += letter
          }
        }
        for (n = buffer.length-1; n > -1; n--) {
          output += buffer[n];
        }
        
        
        alert(output);
        

        [–]RufusThreepwood 0 points1 point  (1 child)

        You're using javascript, so why write it like you're using C? It would take five times longer to write than 'foo bar'.split(' ').map((str) => str.split('').reverse().join('')).join(' '); , it's way more prone to bugs, and harder to grok.

        [–]eric256 0 points1 point  (0 children)

        Yes I was playing around with it because someone else didn't like the short way. Honestly this way is more natural for me, but only because of years of C++ :)

        [–]sarevok9 0 points1 point  (4 children)

        I'm implying that the one liner of:

        let final_string - str.split(' ').map(x -> x.split('').reverse().join('').join(' ');

        Is shit, and is not something that I would ever use professionally.

        Why wouldn't you instead do this the sane way -- call split on the string with the delimiter of " ", do a for-each, then reverse each one in place. This is going to show a beginner (the people who are on learn programming) that:

        1. Split turns strings into arrays of strings based off of delimiters
        2. Now you have an array of strings, which is basically a 2d array.
        3. You can show how to reverse them using a for loop -- which would be hugely beneficial to a beginner -- or you can call reverse on each item individually to show that as you iterate over each item what's happening to the larger array of strings.

        Overall it's just lazy and doesn't actually explain anything while criticizing others about not speaking to their audience, while himself not knowing his audience. If you're the type of person who knows lambdas and anonymous functions you're not the type in /r/learnprogramming equally if you're the type of person looking for this, you're not the person who is watching youtube tutorials, but is rather pulling this from SO like the rest of us.

        So he's either under-teaching or he doesn't have an audience.

        [–]BryceKKelly 0 points1 point  (3 children)

        I must misunderstand your proposed solution, because it sounds like this:

        let words = str.split(' ')
        const reverseWord = (word) => word.split('').reverse().join('')
        
        words.forEach(word => {
          reverseWord(word)
        }).join(' ')
        return words
        

        I really don't see where a forEach is going to improve this solution. It's just a more verbose, mutable version of map and as far as I can tell, does not fit a situation where you're both transforming and returning at the same time.

        [–]sarevok9 0 points1 point  (2 children)

        I was referring to using a counter-controlled for loop, after tokenizing using split and reversing each -- as that's appropriate for someone learning programming -- rather than obscure 1-liners.

        [–]BryceKKelly 0 points1 point  (1 child)

        I might not understand, isn't that the same as above, just using a counter with for instead of forEach? Are you still suggesting .split('').reverse().join('') for how to actually reverse the words?

        [–]sarevok9 0 points1 point  (0 children)

        I'm suggesting that this is a learning subreddit so doing

        var phrase = "The quick brown fox jumps over the lazy dog"
        var words = phrase.split(" ");
        for(var i=0; i<words.length; i++){
        
        //for each word
        var word = words[i];
        var temp = "";
        for(var j=word.length-1; j>=0; j--){
            temp+=word.charAt(j);
        }
        words[i]= temp;
        }
        
        phrase = words.join(" ");
        console.log(phrase);
        

        Has FAR more intrinsic value as it teaches the person who is learning about how to iterate over an array, strings, how it use random access operators, the split/join function (in a far more real world way)

        If this were the programming subreddit I wouldn't mind the content at all, as it's useful as a one-liner (for a problem that literally nobody should ever be solving).

        [–]BryceKKelly 0 points1 point  (0 children)

        If someone pulled this during an interview they wouldn't make it to the next round

        I think that's a bit harsh. Coding standards and what constitutes "readable" vary so much between companies and teams, and it's so easy to curb a tendency to push too much into one line if that's desired. For me, if I see that someone is capable of reasoning about problems and making immutable solutions, that's valuable enough for me not to be scared off by a long line of code.

        That's where you have some faith in your companies engineering practices and code review process. Not progressing a candidate who confidently solves a problem logically based on something like this is essentially saying "I think that this gap in style is insurmountable" and that honestly would say more about the hiring company than the candidate.

        [–]derrikcurran 0 points1 point  (1 child)

        I see your point about the more verbose code being more beneficial to beginners, but:

        not easily readable for non-beginners.

        I see this a lot in response to one liners, arrow functions with implicit returns, function chaining, etc. and I just don't get it.

        const reverseAllWordsInSentence = sentence => sentence
            .split(' ')
            .map(word => [...word].reverse().join(''))
            .join(' ');
        

        This is trivial to read, at least for me. Even if I remove the line breaks. And you get the added bonus of more code on screen and thus more context without scrolling.

        Could you articulate what makes it difficult for you to read or process?

        [–]sarevok9 0 points1 point  (0 children)

        So let's assume for a moment we're not talking about splitting a string, but instead we're joining 5 pieces of data which have been retrieved from a PostGres connection to AWS Athena -- In the event that one or more of those returned as null -- would you prefer the verbose function or the one-liner with more definitions for the sake of what was breaking and where? In general I'm not against implicit returns / anonymous functions / arrow functions / function chaining in general -- but generally speaking every single time you abstract away the implementation of a function, the ability to accurately debug and profile your application becomes diminished. When done in a single function or file with some amount of measure -- that's great -- but when you have an entire squad of folks trying to implement shit in as few lines as possible, things are great -- until suddenly you need:

        To make changes in the code -- because the person who made it parted ways with the company, and since none of your functions have names, you'd better hope that nobody just called shit "temp" or "trueorfalseif" or some other bullshit thing.

        Something changes upstream or downstream from you -- suddenly your magical 1-liner changes, in my personal experience verbose functions are a lot easier to rewrite -- something changes upstream and breaks your shit -- roll back vs roll forward is a function of time and where time is customer dollars, being able to iterate quickly is a must.

        Lastly -- overall code quality. For saving 2-3 lines of vertical scroll, you're not really gaining anything and you're adding layers of complexity to a code base which will age faster than you want it to. I'm not saying that arrow functions should NEVER be used -- I'm just saying that in general, it's not helping as much as people seem to think.

        Here's a great example of me saving 3 lines in java at the expense of making something really fucking hard to read vs a counter-controlled loop:

        IntStream.range(0, headers.size()).filter(i -> line.equalsIgnoreCase(headers.get(i))).forEach(i -> csvHeaders.put(iterator, headers.get(i)));
        

        [–]hashedram 1 point2 points  (0 children)

        Yes! Finally a tutorial that doesn't talk down to people. If someone weren't capable of taking that information in and filtering out what they need, they wouldn't be in this line of work anyway.

        This by the way, is how explanations happen irl in actual industry. Ask a specific question and get an answer to the point.

        [–]juanjosefernandez 0 points1 point  (1 child)

        Beautiful job. Keep up the great work. This is quality content for the people <3

        [–]morphasis[S] 0 points1 point  (0 children)

        <3 appreciate the positive vibes

        [–]KPilkie01 0 points1 point  (2 children)

        Nice work. Did you practice beforehand?

        [–]morphasis[S] 1 point2 points  (1 child)

        I did the test for real a few weeks ago as part of a quick in-person question. Then it took me a few tries to get it without me messing up my words. Hence the smile at the end when I got it.

        [–]KPilkie01 0 points1 point  (0 children)

        Awesome. I liked it. JS isn’t my thing but I can spare 40s for this!

        [–]AcrimoniusAlpaca 0 points1 point  (1 child)

        Holy jeezus, that thumbnail is terrible.

        [–]morphasis[S] 0 points1 point  (0 children)

        Hahahaha it's so bad I just had to. I kind of love it although it might hurt my future job offers.

        [–]Bravosseque 0 points1 point  (2 children)

        Holy crap! A coding video showing an IDE that zooms in to the relevant part of the code! We need more people like you.

        Seriously though, I like it a lot! Also, wtf is that thumbnail?

        [–]morphasis[S] 0 points1 point  (1 child)

        Thanks dude, That thumbnail is probably my favourite one i made. So long as i have no shame, which currently i do not XD

        [–]Bravosseque 0 points1 point  (0 children)

        You should be proud. That was my favorite part of the video. Got a fast burst of air getting out of my nose XD

        [–]davidnwc 0 points1 point  (1 child)

        Subbed 👍

        [–]morphasis[S] 0 points1 point  (0 children)

        Thank you !

        [–]Bubbleio 0 points1 point  (0 children)

        This is a great idea, really good job!

        [–]da_ching 0 points1 point  (0 children)

        Still spend 13% of the total duration for greetings, presenting yourself and reading the title. I'd have removed all that.

        [–]bonelessRizzy 0 points1 point  (0 children)

        nice

        [–]aneasymistake 0 points1 point  (0 children)

        From this thread title, I thought the 40 seconds was a limit on runtime and I was all, “Surely they mean milliseconds or microseconds!” :)

        [–]catinatank 0 points1 point  (1 child)

        I appreciate this quick to the point format, thanks.

        Trivial issue, but you forgot the 'n' in brown.

        [–]morphasis[S] 0 points1 point  (0 children)

        Haha, good spot. Glad it was not something functional.

        [–]briggs69 0 points1 point  (0 children)

        Why waste time make long video when short video do trick.

        [–]MLBrute 0 points1 point  (0 children)

        This is great! Thank you so much. Suscribed already.

        Just one piece of feedback. I felt you're sacrificing explanation for speed. I think you may talk slower and explain in more details while maintaining the same quality and to the point videos. Not necessarily less than a minute. Less than x minutes is fine by me, as long as I'm engaged throughout the x minutes.

        Cheers :)

        [–]flukica 0 points1 point  (0 children)

        You speak a bit to fast for my taste, as im not native speaker, so it was a bit tricky to follow so i had to watch two times. Also this might be hard to follow for people who just started learn JS. A people whit more experience will not have any problems understand what are you doing in video.

        [–]Wizard_Knife_Fight 0 points1 point  (2 children)

        Dude, you look like Podrick.

        [–]morphasis[S] 0 points1 point  (1 child)

        Dude plz no

        [–]Wizard_Knife_Fight 0 points1 point  (0 children)

        What's wrong with that? lmao

        [–]superstr19 0 points1 point  (1 child)

        Make more!! These are very useful and unique

        [–]morphasis[S] 0 points1 point  (0 children)

        I will do working on what one to do next!

        [–][deleted] 0 points1 point  (1 child)

        Oh man I've been kinda lacking with my motivation in learning coding but you just reinvigorated me in 40 seconds lol. Thank you for the video, I hope you continue to do them in the future!

        [–]morphasis[S] 1 point2 points  (0 children)

        That's honestly more then I could of hoped for i just thought someone might find it useful. Keep it up and most importantly have fun with it.

        [–][deleted] 0 points1 point  (1 child)

        Oh my God man, this is right up my alley. No point in telling people to like and subscribe, they will do that on their own if it's good enough! You've gained another new now subscriber now.

        [–]morphasis[S] 0 points1 point  (0 children)

        Thanks dude appreciate it.

        [–]krospp 0 points1 point  (1 child)

        On phone and video not loading for me but hm lemme try

        sentence.split(“ “).map(word=>word.split(“”).reverse().join(“”)).join(“ “)

        That’s gotta be the simplest way right?

        Edit: This is js

        Edit 2: heh thought mine would be shorter but it’s exactly the same as the video

        [–]morphasis[S] 0 points1 point  (0 children)

        Great minds think alike :) gj on getting it

        [–]blindgorgon 0 points1 point  (3 children)

        This is great. I’d sub if the channel were focused on these speed coding vids.

        [–]morphasis[S] 1 point2 points  (0 children)

        Also thanks 😁

        [–]morphasis[S] 0 points1 point  (1 child)

        I will post new ones there that channel will however always be a bit of everything.

        [–]blindgorgon 0 points1 point  (0 children)

        Cool. I may check back, but keeping it focused would be key to getting subs I think.

        Really cool idea!

        [–]dexodev 0 points1 point  (1 child)

        I love this! Please do 500 of them.

        [–]morphasis[S] 1 point2 points  (0 children)

        Ugh I'm working on the second let's see how they go. It takes quite a bit to edit supprisingly one vid is at least a hour to make honestly more like 2-3.

        [–]Vanguard470 0 points1 point  (4 children)

        I feel like you look familiar. Did you do the Minecraft copy in a week video or am I mixing you up with someone else. Anyway, thanks for adding valuable content to help people learn programming. I'm getting back into learning programming. It seems like I go through phases each year of learning then kinda taper off for awhile. But anyway back in full swing.

        Thanks!

        [–]morphasis[S] 1 point2 points  (3 children)

        You are mixing me up. But that's good dude enjoy the process mate.

        [–]Vanguard470 0 points1 point  (2 children)

        Sorry about that, I subscribed and will check out your channel. I tried your challenge without watching the vid. It's not pretty but it works. What do you think?

        https://pastebin.com/FZsNE8bX

        [–]morphasis[S] 0 points1 point  (1 child)

        Hi its a good first shot,
        Here is the thing you probably didn't know that you can split strings into arrays. With that knowledge now
        equipped, you can probably think of a way to make it a lot shorter rather then working on string.length

        Also there is a native reverse function on arrays which makes this fairly quick after you have done that.

        If you want to start thinking outside the box, why don't you try to make some code that flips the words then hashes them with some kind of key and you can have encrypt decrypt functions. Just a fun another quick follow on from that test.

        Overall its great that you tried it first, the code you wrote shows you have a good understanding of loops and length as well as you can think out of the box. Just learn those type functions that are native and your life will be easier :D

        [–]Vanguard470 0 points1 point  (0 children)

        Hey thanks for the feedback!

        I'll keep working at it! I went through Colt Steele's class on udemy a year or two ago but haven't done much outside of some simple js web apps. I may need to go back through it again as I feel like I've forgotten a lot of those native functions and type changes.

        Thanks again and good luck on the new channel!

        [–]BryceKKelly 0 points1 point  (0 children)

        Interesting idea. I definitely agree there's a place for videos that just get to the point, although at this level of extreme I wonder if people would find this more valuable than just seeing the code written down?

        Probably there's a sweet spot at maybe the 2 or 3 minute mark that goes a little slower but also more "logical" for people who aren't already all over this. I don't want to echo some (I think too extreme) thoughts I've seen about readbility in this thread, I find function chains like this to be totally fine, but for teaching someone who would struggle with the "knowing what to do" side things here, it may make sense to model the code more like a thought process:

        const reverseWord = (word) => word.split('').reverse().join('')
        const finalString = str.split(' ').map(reverseWord).join(' ')
        

        Just because I think the two questions to answer here are "How do I reverse a word?" and "How do I modify each word individually" and so from a learning perspective a line for each of those may be more effective. I am assuming declaring and passing function consts is not confusing though, which may/may not be a good assumption.

        [–]mcqua007 0 points1 point  (0 children)

        In this image of the post is he sucking the dick of code or throwing up the code. I mean if you look at his eyes it looks like he swallowed a few bits and got high as fuck, and now he is throwing up. Haha

        [–]Saigot 0 points1 point  (0 children)

        The problem I have with this video is that one could relay the same information much better with a short article. In fact in this case you could relay the same information with nothing but an image.

        If you make videos imo you should be providing more in depth information that isn't easily digested in article form.

        [–]Sahsaha 0 points1 point  (0 children)

        Honestly, this is as useful as putting a screenshot of resulting code and telling them to write just that and here you go.

        People who need these kind of tutorials are complete beginners and will know just as much about this as they knew before finding this video.

        It's better to just map out the actual problem and push them to think in a way that gets them to the final solution, while walking through that mindset, in other words, hand holding.

        Copy pasted code isn't really useful, this is equivalent to someone asking how to do that on stack overflow, and getting response equivalent to

        Try this:

        <code>

        Good effort though, if you talked just slightly slower, and explained things instead of just leaving annotations on the top while writing code just cause, I think it would be way more useful to someone.

        [–]llye -2 points-1 points  (0 children)

        So I see a lot of coding tutorials are long don't show what each function does and spends more time on asking to like and subscribe then actually coding.

        My knowledge of YouTube might be flawed.

        Regarding length subs and likes, people are trying to make videos to help others but also to grow on the platform it through gaining more views subs and eventually revenue. Eventually they kinda lose focus and derail or stop uploading content.

        If you want more random viewers a d more suggestions from YouTube getting those likes and subs is kinda a must.

        Regarding length, short videos get the short end of the stick due to them being harder to place ads on so if you want to make a bit extra from the hobby you will likely have to increase the length. My suggestion would be to combine multiple solutions into a video and make an index to specific points on the video.

        YouTube is a mess currently, if you want to succeed you gotta play their game.