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;
- using System.Text.RegularExpressions;
- using System.IO;
- namespace ConsoleApp1
- {
- class Program
- {
- static void Main()
- {
- using (StreamReader input = new StreamReader("d:/input.txt"))
- {
- using (StreamWriter output = new StreamWriter("d:/output.txt", false))
- {
- var a = input.ReadLine().Split();
- var ans = from u in a
- where u.Length == 2 && int.Parse(u) > 0
- select u;
- foreach (var v in ans)
- output.Write("-" + v + " ");
- }
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement