Löschen das Variable und Saiten



  • Wie tun ich löschen Variablen und Saiten? Für Exempel:

    int var1;
    //Wie löschen das Variable?
    

    Danks!



  • Dont hesitate to describe your problem in a foreign language of your choice 😉

    May be u should provide some more detailed informations about your problem, so people can help u.

    In your example, your variable exists in the stack and not in the heap, so you can only "destroy" that variable by leaving the block formed by "{" and "}"

    e.g.

    {
        int a; // Variable created in Stack-Memory
    }
    // int a does not exist here after leaving the block
    


  • Ok. Thank you! This should help me. I don't even wanna ask how bad my grammar was in that post. I've taken half of German I in school.



  • No Problem. Feel free to ask whatever you want. German, English or even French are possible here to achieve help. Whatever you prefer 😉


Anmelden zum Antworten