#include <stdio.h>

int stack[100];
int top = -1;

void push(int x){
    stack[++top] = x;
}

int pop(){
    return stack[top--];
}

int main() {
    int n = 19;
    int temp = n;

    while (temp > 0) {
        push(temp % 2);
        temp /= 2;
        printf("%d",pop());
    }
}

Embed on website

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