typedef void (*ptr)();
int HHH(ptr P);
void Infinite_Loop()
{
HERE: goto HERE;
return;
}
void Infinite_Recursion()
{
Infinite_Recursion();
return;
}
void DDD()
{
HHH(DDD);
return;
}
int DD()
{
int Halt_Status = HHH(DD);
if (Halt_Status)
HERE: goto HERE;
return Halt_Status;
}
When HHH correctly emulates N steps of the above
functions none of them can possibly reach their own
"return" instruction and terminate normally.
On 3/11/2025 6:15 PM, olcott wrote:
typedef void (*ptr)();
int HHH(ptr P);
void Infinite_Loop()
{
HERE: goto HERE;
return;
}
void Infinite_Recursion()
{
Infinite_Recursion();
return;
}
void DDD()
{
HHH(DDD);
return;
}
int DD()
{
int Halt_Status = HHH(DD);
if (Halt_Status)
HERE: goto HERE;
return Halt_Status;
}
When HHH correctly emulates N steps of the above
functions none of them can possibly reach their own
"return" instruction and terminate normally.
Changing the input is not allowed.
On 2025-03-11 22:31:57 +0000, dbush said:
Changing the input is not allowed.
Why not? There is no requirement that HHH should do anything useful
so it is free to do whatever it does.
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 546 |
Nodes: | 16 (2 / 14) |
Uptime: | 26:04:51 |
Calls: | 10,390 |
Calls today: | 1 |
Files: | 14,064 |
Messages: | 6,417,039 |