CodeMan
Home
Uva
AtCoder
Codechef
Codeforce
Hackerrank
LeetCode
Devskill
TopCoder
Spoj
Algorithm
Python3
Hackerearth
Uri
C++
Data Structure
Sunday, September 15, 2019
AtCoder Beginner Contest 136(B - Uneven Numbers)
#include
<
bits
/
stdc
++.
h
>
using
namespace
std
;
int
main
()
{
int
n
,
ans
=
0
;
cin
>>
n
;
for
(
int
i
=
1
;
i
<=
n
;
i
++)
{
string
s
;
stringstream ss
;
ss
<<
i
;
ss
>>
s
;
if
(
s
.
size
()%
2
)
ans
++;
}
cout
<<
ans
<<
endl
;
return
0
;
}
No comments:
Post a Comment
Newer Post
Older Post
Home
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment