Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- namespace ConsoleApp1
- {
- class Program
- {
- static void Main(string[] args)
- {
- string text = Console.ReadLine();
- var summ = 0;
- for (int i = 0; i < text.Length; i++)
- {
- if (text[i] == 'a')
- Console.WriteLine(summ = summ + 1);
- else if (text[i] == 'e')
- Console.WriteLine(summ = summ + 2);
- else if (text[i] == 'i')
- Console.WriteLine(summ = summ + 3);
- else if (text[i] == 'o')
- Console.WriteLine(summ = summ + 4);
- else if (text[i] == 'u')
- Console.WriteLine(summ = summ + 5);
- }
- Console.WriteLine(summ);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement