您当前的位置: 首页 > 

PolarDay.

暂无认证

  • 6浏览

    0关注

    144博文

    0收益

  • 0浏览

    0点赞

    0打赏

    0留言

私信
关注
热门博文

UVA11988 破碎的键盘(悲剧文本)

PolarDay. 发布时间:2021-02-24 15:55:20 ,浏览量:6

UVA11988 破碎的键盘

紫皮书例题6-4 刚开始学链表想了好久这道题,做个简单的总结。 就用书上的代码

#include
#include
#include
using namespace std;
const int maxn = 100000 + 5;

int last, cur, nextt[maxn]; //光标位于cur号字符的后面

char s[maxn];

int main()
{
    while (scanf("%s", s + 1) == 1)
    {
        int n = strlen(s + 1);
        last = cur = 0;
        nextt[0] = 0;

        for (int i = 1; i             
关注
打赏
1659342973
查看更多评论
0.0418s