您的位置:首页 > 编程语言 > C语言/C++

17907955 2016-05-14 17:17:32 biss A - Summer Camp GNU C++11 Accepted 15 ms 2200 KB

2016-05-14 22:19 609 查看
#include <iostream>
#include <vector>
#include <algorithm>
#include<queue>
using namespace std;

const int N = 1e4 + 100;
string funk(int n){
string s;
while(n){
s = char(n%10+48) + s;
n/=10;
}
return s;
}

int main(){
int pos;
cin >> pos;
string s;
for(int i = 1;i<= pos;i++){
s+=funk(i);
}
cout<<s[pos-1];
}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: