일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 | 29 |
30 | 31 |
Tags
- KOISTUDY
- #hacking
- 리버싱
- grep
- 리눅스
- picoCTF
- writeup
- general skills
- #picoCTF2018
- Aleph One
- 정답
- WEB
- CTF
- cryptography
- dreamhack
- Protostar
- reversing
- 해킹 공부
- 번역
- 시스템해킹
- forensics
- 카이사르
- 스택
- picoCTF2018
- Smashing The Stack For Fun And Profit
- 해설
- 시스템
- 버퍼오버플로우
- write up
- Hxd
Archives
- Today
- Total
Security || AI
[백준(BOJ)] 1110번: 더하기 사이클 본문
#include <stdio.h>
int main()
{
int N, temp, cnt = 0;
scanf("%d", &N);
int input = N;
while(1)
{
temp = (N >= 10)?(int)N/10:0;
temp += N%10;
N = (N%10)*10+temp%10;
cnt++;
if(input == N)
break;
}
printf("%d", cnt);
}
반응형
'Programming > 백준(BOJ)' 카테고리의 다른 글
[백준(BOJ)] 10872번: 팩토리얼 (0) | 2021.02.13 |
---|