Files
OI-source/history_source/ccf 入门篇/U4/4.5.2.cpp
2023-08-03 09:22:52 +08:00

18 lines
187 B
C++
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#include<iostream>
using namespace std;
int main()
{
int n;
while(true)
{
cin>>n;
do
{
cout<<""<<n/2<<""<<""<<n%2<<endl;
n/=2;
}
while(n>0);
cout<<endl;
}
}