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 question_2
- {
- class Program
- {
- static void Main(string[] args)
- {
- string a = Console.ReadLine();
- int length = a.Length;
- int count = 0;
- for (int i = 0; i < length; i++)
- {
- if (char.IsLower(a[i]))
- {
- bool enterbefore = false;
- for (int k = 1; k <= i;k++)
- {
- if (a[i] == a[k])
- {
- break;
- enterbefore = true;
- }
- }
- if (!enterbefore)
- {
- count++;
- }
- }
- }
- Console.WriteLine("The Answer is "+count);
- Console.ReadLine();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement