Masala #QNWA1CAEAU
While #1
n natular sonini agar u juft bo'lsa 2 ga bo'ling agar u toq bo'lsa 1 ni qo'shing. Shu tariqa hosil bo'lgan sonni ham huddi shu amalni bajaring. shu tariqa berilgan son nechta qadamga 1 ga teng bo'lishini aniqlang.
Bitta qatorda n natural soni.
1<=n<=1000
Bitta qatorda n naturlar soni nechta qadamda 1 ga teng bo'lishini chiqaring
# | input.txt | output.txt |
---|---|---|
1 |
10 |
6 |
1. 10/2=5
2. 5+1=6
3. 6/2=3
4. 3+1=4
5. 4/2=2
6. 2/2=1
10 soni uchun 6 ta qadam