A
ASobol
//code.begin()
#include <iostream>
int g (int i)
{
static const int j = i;
return j;
}
int main (int, char**)
{
std::cout << g(0) << g(1) << g (2) << g(3);
return 0;
}
//code.end()
Is output of this program undefined due to C++ standart?
Compilers i have access to (msvc 7.1 and gcc 3.3) both produce "3333"
output.
--Sasha
#include <iostream>
int g (int i)
{
static const int j = i;
return j;
}
int main (int, char**)
{
std::cout << g(0) << g(1) << g (2) << g(3);
return 0;
}
//code.end()
Is output of this program undefined due to C++ standart?
Compilers i have access to (msvc 7.1 and gcc 3.3) both produce "3333"
output.
--Sasha