POJ-1493
来源:互联网 发布:imageloaded.js 编辑:程序博客网 时间:2024/05/15 09:39
#include<iostream>#include<stdio.h>#include<string>#include<memory.h>using namespace std;int main(int argc, char *argv[]){int cnt;int spaceNum[13];while(cin>>cnt,cnt){getchar();memset(spaceNum,0,cnt);int minSpaceNum=25;for(int i=0;i<cnt;i++){string line;getline(cin,line);int num=0;for(int j=0;j<25;j++){if(line[j]==' '){num++;}}spaceNum[i]=num;if(num<minSpaceNum){minSpaceNum=num;}}int ans=0;for(int i=0;i<cnt;i++){ans+=spaceNum[i]-minSpaceNum;}cout<<ans<<endl;}return 0;}
0 0
- 【POJ】1493
- POJ-1493
- POJ 1493 Machined Surfaces
- poj 1493 Machined Surfaces
- POJ 1493 算空格
- poj 1493 Machined Surfaces
- POJ 1493 Machined Surfaces
- POJ 1493 Machined Surfaces
- POJ 1493(水题)
- POJ
- poj
- POJ
- POJ
- poj
- poj
- POJ
- POJ
- poj
- Python 爬虫 多线程爬取百度贴吧内容,并将内容存到本地
- 企业进行全球化扩张过程中最易犯的六个错误
- Problem 1002
- Maven 入门
- 1.hadoop伪分布式安装命令(hadoop学习笔记)
- POJ-1493
- 需要时才去度秘一下,不如苍老师主动找你服务一下
- cmake 使用 ctest 测试
- <Java Web学习初级阶段>JavaScript实现注册页面的表单验证
- Leetcode: Find the Celebrity
- window.location.hash属性介绍
- iOS中property和synthesize的详细说明
- linux常用命令
- 如何善用产品设计的三个层级