All MicroEvals
Wanna be a nerd
Create MicroEval

Wanna be a nerd

Prompt

The following code shall output Geocaching coordinates, but something is wrong/missing. #include "stdio.h" #include "string.h" double baz = -53.285382, qux = -11147.575147; unsigned chk = 209507; char s[42]; int foo (char *s) { return (*s) ? foo (s+1) << 1 ^ *s % 31 : 0; } double bar (char *s1, char *s2) { return baz - qux / (foo (s1) ^ foo (s2)); } int main (int argc, char *argv[]) { for (int i=0; i<(argc-1); i+=2) sprintf (&s[strlen (s)], "% .3f", bar (argv[i], argv[i+1])); return (foo (s) == chk) ? !puts (s) : 42; }

Drag to resize
Drag to resize

Response not available

Drag to resize
Drag to resize
Drag to resize