当前位置:网站首页>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;
}
边栏推荐
- JS Part III
- Qt学习22 布局管理器(一)
- Analysis of the characteristics of page owner
- Onmenusharetimeline custom shared content is invalid, and the title and icon are not displayed
- Redis:字符串類型數據的操作命令
- Go language web development series 29: Gin framework uses gin contrib / sessions library to manage sessions (based on cookies)
- js . Find the first palindrome string in the array
- Qt学习23 布局管理器(二)
- Configure stylelint
- QT learning 19 standard dialog box in QT (top)
猜你喜欢

Implementation of Muduo asynchronous logging

Common network state detection and analysis tools

Comprehensive case of MySQL data addition, deletion, modification and query
![[understanding by chance-37]: the structure of human sensory system determines that human beings are self-centered](/img/06/b71b505c7072d540955fda6da1dc1b.jpg)
[understanding by chance-37]: the structure of human sensory system determines that human beings are self-centered

GoLand 2021.2 configure go (go1.17.6)

UiO-66-COOH装载苯达莫司汀|羟基磷灰石( HA) 包裹MIL-53(Fe)纳米粒子|装载黄芩苷锰基金属有机骨架材料

Configure stylelint
![Mysql:insert date:SQL 错误 [1292] [22001]: Data truncation: Incorrect date value:](/img/2f/33504391a661ecb63d42d75acf3a37.png)
Mysql:insert date:SQL 错误 [1292] [22001]: Data truncation: Incorrect date value:

Page generation QR code
![[Jilin University] information sharing of postgraduate entrance examination and re examination](/img/1d/550a991385b842a21e2b301725407e.png)
[Jilin University] information sharing of postgraduate entrance examination and re examination
随机推荐
Uio-66-cooh loaded bendamostine | hydroxyapatite (HA) coated MIL-53 (FE) nanoparticles | baicalin loaded manganese based metal organic skeleton material
Golang - command line tool Cobra
Depth and breadth first traversal of tree (regardless of binary tree)
JVM family - overview, program counter day1-1
Common mixins
How to promote the progress of project collaboration | community essay solicitation
Go language web development series 30: gin: grouping by version for routing
Qt学习18 登录对话框实例分析
Dlopen() implements dynamic loading of third-party libraries
Conversion function and explicit
UiO-66-COOH装载苯达莫司汀|羟基磷灰石( HA) 包裹MIL-53(Fe)纳米粒子|装载黄芩苷锰基金属有机骨架材料
How to bold text in AI
Qt学习25 布局管理器(四)
28: Chapter 3: develop Passport Service: 11: define attributes in the configuration file, and then obtain them in the code;
Redis:字符串類型數據的操作命令
Leetcode-1175. Prime Arrangements
Generate directories from web content
Programmable logic device software testing
Go 1.16.4: manage third-party libraries with Mod
Uniapp skills - scrolling components -1