23 Eki 2020 #1 Guccimang G Üye Katılım 23 Eki 2020 Mesajlar 1 Tepki puanı 0 Yaş 26 5 HİZMET YILI Hello, can someone help me, I want the c ++ console name and exe name to change when opened and closed.Please C++: #include <iostream> int main() { std::cout << "Hello World!\n"; }
Hello, can someone help me, I want the c ++ console name and exe name to change when opened and closed.Please C++: #include <iostream> int main() { std::cout << "Hello World!\n"; }
23 Eki 2020 #2 noth4xu3lyn N Üye Katılım 23 Eyl 2020 Mesajlar 36 Tepki puanı 27 5 HİZMET YILI C++: std::string random_string( const int len ) { const std::string alpha_numeric( "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890" ); std::default_random_engine generator{ std::random_device{}( ) }; const std::uniform_int_distribution< std::string::size_type > distribution{ 0, alpha_numeric.size( ) - 1 }; std::string str( len, 0 ); for ( auto &it : str ) { it = alpha_numeric[ distribution( generator ) ]; } return str; } C++: SetConsoleTitle( random_string( length_of_string ).c_str( ) );
C++: std::string random_string( const int len ) { const std::string alpha_numeric( "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890" ); std::default_random_engine generator{ std::random_device{}( ) }; const std::uniform_int_distribution< std::string::size_type > distribution{ 0, alpha_numeric.size( ) - 1 }; std::string str( len, 0 ); for ( auto &it : str ) { it = alpha_numeric[ distribution( generator ) ]; } return str; } C++: SetConsoleTitle( random_string( length_of_string ).c_str( ) );
24 Eki 2020 #3 Kantheri K Üye Katılım 19 Eki 2020 Mesajlar 46 Çözümler 1 Tepki puanı 1 Yaş 23 5 HİZMET YILI Did it help you?