#include <stdio.h>

void change(int n) {
    if (n==0) return;
    else {
        change(n/2);
        printf("%d",n%2);
         }
 }

int main() {
    int n;
    scanf("%d",&n);
    if (n==0) {
        printf("0");
        return 0;
    }
    change(n);
    return 0;
}

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: