필터 지우기
필터 지우기

how can i do this?

조회 수: 2 (최근 30일)
bob  shot
bob shot 2012년 12월 12일
Write a program that reads a string of characters, say a piece of an article in a magazine, and determines how many times each vowel appears in the passage.
  댓글 수: 6
Walter Roberson
Walter Roberson 2012년 12월 12일

댓글을 달려면 로그인하십시오.

답변 (1개)

Image Analyst
Image Analyst 2012년 12월 12일
Here's a few hints for you, assuming you just type in the text from the article into your m-file:
s = 'abcdefGHIJKLmnopqRSTUVwxyz'
letterIndex = lower(s) - 'a'
% Now look up the hist() function
That should be enough to start you off.
  댓글 수: 1
Walter Roberson
Walter Roberson 2012년 12월 12일
Though it is admittedly tricky to figure out when "y" is a vowel and when it is a consonant.

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Introduction to Installation and Licensing에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by