Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
78803 邓嘉懿 字符串拼接 C++ Accepted 1 MS 276 KB 261 2024-06-29 10:54:14

Tests(10/10):


Code:

#include<bits/stdc++.h> using namespace std; char s; int main(){ char a[1000],b[1000]; int c; scanf("%s %s",a,b); cin>>c; int len=strlen(a); int len1=strlen(b); if(c>len){ cout<<b[c-len-1]; }else{ cout<<a[c-1]; } return 0; }