Advertisement
Guest User

FindNumber

a guest
May 5th, 2016
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.33 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4.  
  5. class Program
  6. {
  7.     static void Main()
  8.     {
  9.         List<int> a = Console.ReadLine().Split().Select(int.Parse).ToList();
  10.         int b = int.Parse(Console.ReadLine());
  11.         a = a.FindAll(x => x==b).ToList();
  12.         Console.WriteLine(a.Count());
  13.     }
  14. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement