What is global Scope? - (Arduino Uno Programming for Beginners)

Поделиться
HTML-код
  • Опубликовано: 2 окт 2024

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

  • @deatenebrae5580
    @deatenebrae5580 9 месяцев назад

    Also a good intro to scopes in general :)

  • @uffeborgstroemknudsen2662
    @uffeborgstroemknudsen2662 9 месяцев назад

    Thank you! This is a good intro series.

  • @Volker-Dirr
    @Volker-Dirr 9 месяцев назад

    Talking about scopes you might have also told about problems like this: (Or as a task for the user)
    int a=5;
    {
    int a=6;
    Serial.println(a);
    }
    Serial.println(a);
    Brings me to the question if there is a linter or code analyses tool for Arduino like cppcheck, clang-tidy, ... in c++.

    • @playduino
      @playduino  9 месяцев назад

      Oh, yes - I should talk about variable shadowing to another video, because this can be quite confusing. I'm afraid inside of the Arduino IDE, there is no static code check.

  • @310765
    @310765 5 месяцев назад

    Hi Playduino ‘If (true)’ if ‘what’ is true? Thanks 😊

    • @playduino
      @playduino  5 месяцев назад +1

      if (true) is always to, so whatever is written inside the {} is always executed. You will not find this in a normal program because it makes no sense, I just used it to create a different scope :)