#include <cstdio>
#include <cstring>
int main(){
char str[100];
scanf("%s",str);
int len=strlen(str);
int ans=10;
for(int i=1;i<len;i++){
if(str[i-1]==str[i])ans+=5;
else ans+=10;
}
printf("%d",ans);
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
884 KB |
Output is correct |
2 |
Correct |
0 ms |
884 KB |
Output is correct |
3 |
Correct |
0 ms |
884 KB |
Output is correct |
4 |
Correct |
0 ms |
884 KB |
Output is correct |
5 |
Correct |
0 ms |
884 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
884 KB |
Output is correct |
2 |
Correct |
0 ms |
884 KB |
Output is correct |
3 |
Correct |
0 ms |
884 KB |
Output is correct |
4 |
Correct |
0 ms |
884 KB |
Output is correct |
5 |
Correct |
0 ms |
884 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
884 KB |
Output is correct |
2 |
Correct |
0 ms |
884 KB |
Output is correct |
3 |
Correct |
0 ms |
884 KB |
Output is correct |
4 |
Correct |
0 ms |
884 KB |
Output is correct |
5 |
Correct |
0 ms |
884 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
884 KB |
Output is correct |
2 |
Correct |
0 ms |
884 KB |
Output is correct |
3 |
Correct |
0 ms |
884 KB |
Output is correct |
4 |
Correct |
0 ms |
884 KB |
Output is correct |
5 |
Correct |
0 ms |
884 KB |
Output is correct |
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
0 ms |
884 KB |
Output is correct |
2 |
Correct |
0 ms |
884 KB |
Output is correct |
3 |
Correct |
0 ms |
884 KB |
Output is correct |
4 |
Correct |
0 ms |
884 KB |
Output is correct |
5 |
Correct |
0 ms |
884 KB |
Output is correct |