Naming is Hard -- But Not With Java

Поделиться
HTML-код
  • Опубликовано: 31 мар 2023
  • "There are only two hard things in Computer Science: cache invalidation and naming things."
    -- Phil Karlton
    martinfowler.com/bliki/TwoHar...
    ...not with Java.
    See you at live, virtual workshops: airhacks.live
    Checkout the: airhacks.fm podcast
    Any questions left? See you at the airhacks.tv
    Join the airhacks discord server: / discord
    #airhacks
  • НаукаНаука

Комментарии • 36

  • @undeuxtroiskid
    @undeuxtroiskid Год назад +20

    I prefer the saying "There are two hard things in computer science; cache invalidation, naming things, and off by one errors."

    • @bienadam
      @bienadam  Год назад +1

      Yes, but it is not the original version: www.karlton.org/2017/12/naming-things-hard/ Thanks for watching!

    • @GeraldOSullivan
      @GeraldOSullivan Год назад

      @@bienadam It's not the original version. It's a joke. "Off by one errors" Geddit? No? /*sigh*/
      But still, I love the var var!

    • @bienadam
      @bienadam  Год назад +1

      @@GeraldOSullivan It was a semi joke coined by Phil Karlton. In the first version there was no mention of "Off by one errors." But I like the "extended" version better. Hopefully I got you :-)

    • @GeraldOSullivan
      @GeraldOSullivan Год назад +1

      @@bienadam class FunnierJoke extends KarltonJoke
      OK, you got me :))

    • @bienadam
      @bienadam  Год назад

      assertTrue(understood);

  • @georgetsiklauri
    @georgetsiklauri Год назад +2

    I loved this mock. Thanks, Adam, well done. I would actually negate this to "never use "var" for anything in Java".

  • @tobyzieglerrr
    @tobyzieglerrr Год назад +5

    Nice. Happy Aprils fools day to everyone 🎉

    • @bienadam
      @bienadam  Год назад +3

      This beautiful pattern will also work perfectly in May! 🙂

  • @ebuzertahakanat
    @ebuzertahakanat Год назад +3

    i was this close to correct him not realizing it is an april fools joke

    • @bienadam
      @bienadam  Год назад +2

      Correcting me? Then I would vote your comment down :-)

  • @FiveNineO
    @FiveNineO Год назад +2

    That's beautiful, very clean 👍

    • @bienadam
      @bienadam  Год назад +1

      +1 Now I can start to ask: why you are still using Kotlin and not Java?

  • @marcinkwapisz7752
    @marcinkwapisz7752 Год назад +5

    I forgot about Fools Day. But I have better example of interesting naming in Java. Try this:
    int Integer = 7;
    Integer Float = 9;
    System.out.println(Integer);
    System.out.println(Float);
    System.out.println(Float.MAX_VALUE);

  • @mikekachaluba2321
    @mikekachaluba2321 Год назад +1

    This is a horrible joke You got me 😂

    • @bienadam
      @bienadam  Год назад +1

      It is a compilable joke! :-) Thanks for watching!

  • @Apuntesdejava
    @Apuntesdejava Год назад +2

    everything is very clear. How come I did not think of it before!😅😅

    • @bienadam
      @bienadam  Год назад +2

      ...because you didn't meditated long enough :-)

    • @michimarz
      @michimarz Год назад

      @@bienadam Sensei Adam, is the registration for the next meditation retreat already open?

  • @user-me1rw8zk5g
    @user-me1rw8zk5g Год назад +2

    Var var var var var😅

  • @HelmutGehrer
    @HelmutGehrer Год назад +2

    Happy April 1st 😂

  • @lprimak
    @lprimak Год назад

    nice one!!!

  • @mahmoudelsonbati8673
    @mahmoudelsonbati8673 Год назад +1

    you got me :D

  • @HanWae363
    @HanWae363 Год назад +2

    Thank God it's apr 1st

    • @bienadam
      @bienadam  Год назад +2

      I crafted this code to work on all possible dates :-)

  • @blankbox33
    @blankbox33 Год назад +1

    Hello Adam, I m new to java could you please suggest me any website or ebooks for enhancing my data structure and algorithm skills in Java. Anything you know which is important kindly share.. Thank you in advance.. 😊

    • @bienadam
      @bienadam  Год назад +1

      Checkout e.g. javachallengers.com/category/data-structures/ I had a chat with the author at: airhacks.fm/#episode_248 Thanks for watching!

    • @blankbox33
      @blankbox33 Год назад

      @@bienadam Thank so much Adam.. you rock !!

  • @MartinPape
    @MartinPape Год назад +3

    😂

  • @zickzack987
    @zickzack987 Год назад +1

    Unfortunately I see this very often 😑

    • @bienadam
      @bienadam  Год назад +1

      It's absolutely sufficient to watch this video only once :-) Thanks for watching this video multiple times! :-)

  • @MichaelBornholdtNielsen
    @MichaelBornholdtNielsen Год назад +1

    Cooking this code in the afternoon it should be a int with the value of 418 instead of a string being returned.
    #rfc2324