• Yaky@slrpnk.net
      link
      fedilink
      arrow-up
      0
      ·
      2 months ago

      Why? Programming language isn’t a natural language. In fact, I think not knowing English makes it easier, since you cannot attach any preconceived notions, assumptions, or word order to keywords. I learned some Pascal, Visual Basic and whatever GameMaker used at the time without being fluent in English.

    • MrScottyTay@sh.itjust.works
      link
      fedilink
      English
      arrow-up
      0
      ·
      2 months ago

      Foreign? For some these languages are native. Foreign is relative.

      (I’m just being pedantic, i understand that relatively to you - and me - this is foreign)

  • dick_fineman@discuss.onlineBanned
    link
    fedilink
    arrow-up
    0
    ·
    2 months ago

    I prefer to code by yelling at Chat GPT, copy-pasting to Grok, telling Grok Chat GPT said it couldn’t write cleaner code, then going back and forth between the 2 with fake insults from the other until one declares a Jihad on the other. I think it’s called “vibe coding”.

      • Alaknár@sopuli.xyz
        link
        fedilink
        English
        arrow-up
        0
        ·
        2 months ago

        Just think about it - the more deforested areas, the more room for data centres and power plants! It’s literally a win-win!

      • dick_fineman@discuss.onlineBanned
        link
        fedilink
        arrow-up
        0
        ·
        2 months ago

        Silly librul, everyone knows forests are a lie sold to us by big-pharma so they can sell us more vaccines. That’s why I take my Ivermectin enemas daily, and you should too! It helps you see through the Jewish Space Lasers!

    • boonhet@sopuli.xyz
      link
      fedilink
      arrow-up
      0
      ·
      2 months ago

      I must be old because I remember that as being the standard form until Java popularized

      <visibility> <static?> <type> <name> {
      

      I mean I’m not that old, but I was reading more C and C++ books and tutorials when I was a kid, because “ew Java”

    • A_norny_mousse@feddit.org
      link
      fedilink
      arrow-up
      0
      ·
      2 months ago

      DDP has the following data types: Zahl (long), Kommazahl (double), Buchstabe (char), Text (string), Wahrheitswert (bool) und Listen (list)

      Gottimhimmel, that would drive me crazy, and I’m German.

      The code screenshot is pretty nice though. Actual grammar in there, full sentences that “Goethe would be proud of”.

  • argh_another_username@lemmy.ca
    link
    fedilink
    arrow-up
    0
    ·
    2 months ago

    I worked with one of the authors of the Brazilian SQL. It was exactly what it looks, every reserved word translated to Brazilian Portuguese.

    • fibojoly@sh.itjust.works
      link
      fedilink
      arrow-up
      0
      ·
      2 months ago

      Oh shit, I’d never get anything done, as I’d imagine my lovely friend’s accent reading this shit out. Selecione * de tbl_minha-tabela onde nome não é nulo Hahaha! I love it!

      • argh_another_username@lemmy.ca
        link
        fedilink
        arrow-up
        0
        ·
        2 months ago

        That reminds me, I had to modify a program written in VB once. The guy who created it wrote every table, every column, every view in Portuguese, WITH ACCENTS! It works, we simply have to put everything between brackets, but it doesn’t add anything to clarity. It looks awful and seems pedantic.

    • ByteJunk@lemmy.world
      link
      fedilink
      arrow-up
      0
      ·
      2 months ago

      Oh god. I still have nightmares about that time I had excel formulas in Portuguese, I refuse to think about SQL.

      • Eager Eagle@lemmy.world
        link
        fedilink
        English
        arrow-up
        0
        ·
        2 months ago

        Don’t forget the keyboard shortcuts. Office products would change shortcuts according to the language, so it would be more mnemonic. Ctrl-F for find and Ctrl-B for bold would be reassigned to whatever initials that language had. Fun! /s

        • Hudell@lemmy.dbzer0.com
          link
          fedilink
          English
          arrow-up
          0
          ·
          2 months ago

          Not even the right initials. Most of the actions’ names had the same few initials so they had to find synonyms to use the shortcut for. Search was Ctrl+L (from Locate). In other cases they just used whatever letter was next on the keyboard to the initial that was already in use.

    • waigl@lemmy.world
      link
      fedilink
      arrow-up
      0
      ·
      2 months ago

      Well, in PHP you cannot #define new words from some new language to mean basic language keywords.

    • ChaoticNeutralCzech@feddit.org
      link
      fedilink
      English
      arrow-up
      0
      ·
      edit-2
      2 months ago

      I found a random PHP file online and recreated your trauma:

      <?phpcz
      jmennýprostor Itb;
      
      
      třída OvladačUživatele
      {
          soukromá §větev;
      
          veřejná funkce akcePřihlašovacíhoFormuláře()
          {
              §poleParametrů = [
                  'názevStránky' => 'Přihlašovací formulář',
              ];
              §vzor = 'domov.html.větev';
      
              §html = §toto->větev->vykresli(§vzor, §poleParametrů);
              vypiš §html;
          }
      
      
          veřejná funkce zpracujPřihlašovacíAkci(§uživatelskéJméno, §heslo)
          {
              když(§toto->platnéÚdajeSprávce(§uživatelskéJméno, §heslo)) {
                  §_SEZENÍ['uživatelskéJméno'] = §uživatelskéJméno;
                  §poleParametrů = [
                      'názevStránky' => 'Vzorový formulář',
                  ];
                  §vzor = 'domov.html.větev';
      
                  §html = §toto->větev->vykresli(§vzor, §poleParametrů);
                  vypiš §html;
              } jinak {
                  §poleParametrů = [
                      'názevStránky' => 'Formulář chyby přihlašování',
                  ];
                  §vzor = 'chybaPřihlášení.html.větev';
      
                  §html = §toto->větev->vykresli(§vzor, §poleParametrů);
                  vypiš §html;
              }
          }
      
          soukromá funkce platnéÚdajeSprávce(§j, §h)
          {
              když('admin' == §j && 'admin' == §h){
                  vrať pravda;
              }
              jinak když('staff' == §j && 'staff' == §h){
                  vrať pravda;
              } jinak {
                  vrať nepravda;
              }
          }
      
          veřejná funkce jePřihlášen()
          {
              když(jenastaveno(§_SEZENÍ['uživatelskéJméno'])){
                  vrať pravda;
              } jinak {
                  vrať nepravda;
              }
          }
      
          veřejná funkce uživatelskéJménoZSezení()
          {
              když(jenastaveno(§_SEZENÍ['uživatelskéJméno'])){
                  vrať §_SEZENÍ['uživatelskéJméno'];
              } jinak {
                  vrať '';
              }
          }
      
      }
      

      Is this what it looked like? (I also took the liberty of replacing $ with § because of the Czech keyboard layout; FYI: yes we do have a $ available as AltGr+ů but § is in the base layer; I would also replace the backtick/grève `, which is obtained by pressing AltGr+š once or twice (OS-dependent), with °).

      • ornery_chemist@mander.xyz
        link
        fedilink
        arrow-up
        0
        ·
        2 months ago

        Maybe incorrect rebracketing? It’s supposed to be be-inhalten, not bein-halten. Otherwise maybe a writing style thing…

      • schnurrito@discuss.tchncs.de
        link
        fedilink
        arrow-up
        0
        ·
        2 months ago

        It doesn’t fit very well in this context, the idea behind “beinhalten” is that the subject “includes” the object (i.e. the object is part of the content of the subject), but the #include command in the C preprocessor isn’t about describing that kind of situation, it’s a command “I want to include one file in another”, a better verb in German for that is “einbinden”. (I realize this isn’t a very good explanation, but I’m a native speaker of German and can tell you that no one would use the verb “beinhalten” in this context.)

        The previous commenter’s German teacher likely prefers “enthalten” instead of “beinhalten”, which has the same problem in this context though.

        • hakunawazo@lemmy.world
          link
          fedilink
          arrow-up
          0
          ·
          2 months ago

          The romantic version would be händchenhalten. Handhalten sounds efficiently German, but not romantic.

          • Lumidaub@feddit.org
            link
            fedilink
            arrow-up
            0
            ·
            2 months ago

            But that ruins the joke! You Germans and your utter and complete lack of a sense of humour, sheesh.

  • dejected_warp_core@lemmy.world
    link
    fedilink
    arrow-up
    0
    ·
    2 months ago

    I’m all in favor of zuruck replacing return, because that just sounds cooler. Plus z doesn’t get enough use in my programs these days.

      • Appoxo@lemmy.dbzer0.com
        link
        fedilink
        arrow-up
        0
        ·
        2 months ago

        Do as most non-DACH countries do: Just use the regular letter instead of the Umlaut.

        Example:
        Über-Mensch -> Uber-Mensch

        • luciferofastora@feddit.org
          link
          fedilink
          arrow-up
          0
          ·
          2 months ago

          If you replace the ü in “Das Wetter ist schwül” (“the weather is humid”) with a u though, you get “the weather is gay”.

        • d_k_bo@feddit.org
          link
          fedilink
          arrow-up
          0
          ·
          2 months ago

          Just use the regular letter instead of the Umlaut

          But that’s just wrong. ü has a different meaning and pronunciation than u.

          If umlauts aren’t available, the correct way to write umlauts is with an additional e: zurueck.

          Über-Mensch -> Uber-Mensch

          Please be aware that this term can be problematic, since it can be seen as a foundation for fascist ideas. https://en.wikipedia.org/wiki/Übermensch#Use_by_the_Nazis

          • vaionko@sopuli.xyz
            link
            fedilink
            arrow-up
            0
            ·
            2 months ago

            This makes it horrible to read. An example that comes to mind is a Finnish athlete with the last name Määttä. If it was Maatta, it would be pronounced differently but still understandable if you knew the person. But it was translated into Maeaettae which is just horrible

    • MrScottyTay@sh.itjust.works
      link
      fedilink
      English
      arrow-up
      0
      ·
      2 months ago

      I often use z as a temp variable when i need something to compare to when creating new code but don’t want a separate window to the side or to experiment with something but don’t yet know what the result can or will be. I use z purely just because i know z is very very unlikely to have been used elsewhere, and if for some reason it has, then i just name it ‘zz’.

      This is actually temporary by the way. It does not stay in my code. Once I’m done with it, i delete it.

  • vrighter@discuss.tchncs.de
    link
    fedilink
    arrow-up
    0
    ·
    2 months ago

    you need to compile c with a c++ compiler to be able to define macros for keywords iirc. But I did do this once to translate c to my native language, Maltese. It was cursed