当前位置:网站首页>Exercise 7-6 count capital consonants
Exercise 7-6 count capital consonants
2022-07-03 14:09:00 【ᯤ⁹ᴳ⁺ ·】
exercises 7-6 Count capital consonants (15 branch )
English consonants are divided by A、E、I、O、U Letters other than . This question requires the preparation of procedures , Statistics in the given string Capitalization The number of consonants .
Input format :
The input gives no more than 80 Characters 、 A string that ends with a carriage return .
Output format :
The output gives the number of uppercase consonants in the string in one line .
sample input :
HELLO World!
sample output :
4Code
#include<stdio.h>
int main(){
char a[80];
int d,i,j,k;
i=0;
while((d=getchar())!='\n'){
a[i]=(char)d;
i++;
}
a[i]='\0';
k=0;
for(j=0;j<i;j++){
if(a[j]>='A'&&a[j]<='Z'&&a[j]!='A'&&a[j]!='E'&&a[j]!='I'&&a[j]!='O'&&a[j]!='U'){
k++;
}
}
printf("%d",k);
return 0;
}
边栏推荐
- Scroll detection, so that the content in the lower right corner is not displayed at the top of the page, but is displayed as the mouse slides
- Duet date picker (time plug-in that can manually enter the date)
- QT learning 23 layout manager (II)
- Message subscription and publishing
- QT learning 22 layout manager (I)
- 【吉林大学】考研初试复试资料分享
- Golang - command line tool Cobra
- JS continues to explore...
- jvm-类加载
- The small project (servlet+jsp+mysql+el+jstl) completes a servlet with login function, with the operation of adding, deleting, modifying and querying. Realize login authentication, prevent illegal log
猜你喜欢
[email protected] Nanoparticles) | nano metal organic framework carry"/>Metal organic framework material zif-8 containing curcumin( [email protected] Nanoparticles) | nano metal organic framework carry

JVM class loading

Installation impression notes
[email"/>Folic acid modified metal organic framework (zif-8) baicalin loaded metal organic framework composite magnetic material (AU- [email

GoLand 2021.1.1: configure the multi line display of the tab of the open file

Multi person collaborative data annotation based on Baidu brain easydata from scratch
[email protected]纳米颗粒)|纳米金属有机框架搭载雷帕霉素|科研试剂"/>金属有机骨架材料ZIF-8包载姜黄素([email protected]纳米颗粒)|纳米金属有机框架搭载雷帕霉素|科研试剂

JS first summary

Global event bus

QT learning 23 layout manager (II)
随机推荐
Metal organic framework material zif-8 containing curcumin( [email protected] Nanoparticles) | nano metal organic framework carry
Reflection -- basic usage
Go language web development series 30: gin: grouping by version for routing
Qt学习18 登录对话框实例分析
Go language unit test 3: go language uses gocovey library to do unit test
Spring cup eight school league
Redis:字符串类型数据的操作命令
Another industry has been broken by Chinese chips. No wonder the leading analog chip companies in the United States have cut prices and sold off
Use and design of Muduo buffer class
Go language web development series 25: Gin framework: using MD5 to verify the signature for the interface station
Back to top implementation
JVM runtime data area
Multi person collaborative data annotation based on Baidu brain easydata from scratch
QT learning 22 layout manager (I)
玖逸云黑免费无加密版本源码
3D视觉——2.人体姿态估计(Pose Estimation)入门——OpenPose含安装、编译、使用(单帧、实时视频)
Uniapp skills - dom display and hiding
Similarities and differences of sessionstorage, localstorage and cookies
Go language web development series 28: solve cross domain access of CORS with gin contrib / CORS
Use vscode to view hex or UTF-8 codes