📄 hcbm.cpp
字号:
//多媒体技术和应用
//行程编码问题
//黄俊冬 时间2004-11-16
#include<iostream.h>
#define MAXSIZE 100
void main()
{
char str[MAXSIZE],ch,temp;
int i,RepCount;
cout<<"please input the code:";
cin>>str;
temp=str[0];
ch=str[0];
//flag=0;
RepCount=0;
i=0;
while(ch!='\0')
{
RepCount=1;
cout<<ch;
// ch2=ch1;
i++;
ch=str[i];
while(temp==ch)
{
// flag=1;
RepCount++;
i++;
ch=str[i];
}
temp=ch;
if(RepCount>1)
{
cout<<"!"<<RepCount<<" ";
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -