{}
run-icon
main.cpp
#include <iostream> int main() { const char* str1 = "hello"; const char* str2 = "hello"; std::cout << "Address of str1: " << static_cast<const void*>(str1) << std::endl; std::cout << "Address of str2: " << static_cast<const void*>(str2) << std::endl; return 0; }
Output