Run ID | Author | Problem | Lang | Verdict | Time | Memory | Code Length | Submit Time |
---|---|---|---|---|---|---|---|---|
41181 | Hyma | 字符串 | C++ | Compile Error | 0 MS | 0 KB | 291 | 2024-02-20 09:15:07 |
#include<bits/stdc++.h> using namespace std; string s; int main() { getline(cin,s)//输入整行字符串,可以有空格string类输入 //gets(a);字符串的整行输入 for(int i=s.size()-1;i>=0;i--) {//s.size()存放的是结束符"/0"; cout<<s[i]; { return 0; }