← Back to archive

Stdle #171 · comparisons · 2026-11-24

What does this C snippet output?

A past puzzle — fully playable. 4 attempts, hints on wrong guesses.

#include <stdio.h>
int main(void) {
int r = -3 % 2;
int s = 3 % -2;
printf("%d %d\n", r, s);
return 0;
}
Comparisons
4 attempts left

Answer & explanation