05-07-2012, 10:00 PM
ITALIANO:
Raga ho un problema col c++..
se io utilizzo il ciclo for per decryptare il pacchetto del login di nostale il contenuto della stringa login_packet rimane solamente nel ciclo for..
mi sorge una domanda:
come posso fare per utilizzare questo contenuto al di fuori del ciclo for?
esempio:
chiedo aiuto a chi si intende piu di me in questo passaggio
INGLESE:
i have a C++ problem..
if i use the cycle for to decrypt the nostale login package, the content of the string login_packet remains only in the cycle for ...
cycle for = for( ; ; ){...}
i have a question:
how i use this content outside the cycle for?
example:
Raga ho un problema col c++..
se io utilizzo il ciclo for per decryptare il pacchetto del login di nostale il contenuto della stringa login_packet rimane solamente nel ciclo for..
mi sorge una domanda:
come posso fare per utilizzare questo contenuto al di fuori del ciclo for?
esempio:
Codice:
std :: string str;
for (...) {
...
str = "ciao"; / / Ho una stringa
}
/ / Come chiamo stringa al di fuori del ciclo for?
std :: cout << str; / / errore, la stringa = "";
chiedo aiuto a chi si intende piu di me in questo passaggio
INGLESE:
i have a C++ problem..
if i use the cycle for to decrypt the nostale login package, the content of the string login_packet remains only in the cycle for ...
cycle for = for( ; ; ){...}
i have a question:
how i use this content outside the cycle for?
example:
Codice:
std::string str;
for(...){
...
str = "hello"; // i have a string
}
// how call string outside the cycle for?
std::cout << str; // error, the string = "";