This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
class Subset Sums //KatyaMarincheva | |
{ | |
static int[] numbers; | |
static int N; | |
static bool solution = false; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
class SortedSubsetSums //KatyaMarincheva | |
{ | |
static List<List<int>> subsets = new List<List<int>>(); | |
static int[] numbers; | |
static int N; | |
static bool solution = false; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
class LongestIncreasingSequence | |
{ | |
static void Main(string[] args) | |
{ | |
int[] nums = Array.ConvertAll(Console.ReadLine().Split(' '), s => int.Parse(s)); | |
Dictionary<int, List<int>> sorted = new Dictionary<int, List<int>>(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
class SequencesEqualStrings | |
{ | |
static void Main(string[] args) | |
{ | |
string[] input = Console.ReadLine().Split(' '); | |
var groups = input.GroupBy(name => name); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Linq; | |
class CategorizeNumbers | |
{ | |
static void Main(string[] args) | |
{ | |
double[] nums = Array.ConvertAll(Console.ReadLine().Split(' '), s => double.Parse(s)); | |
var floatNums = nums.Where(i => i != (int)i); | |
var roundNums = nums.Where(i => i == (int)i); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
class SortedSubSums | |
{ | |
static void Main() | |
{ | |
// on the third test prints twice the results??? | |
int n = int.Parse(Console.ReadLine()); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
class LegoBlocks | |
{ | |
static void Main(string[] args) | |
{ | |
int n = int.Parse(Console.ReadLine()); | |
bool fit = true; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
class StuckNumbers | |
{ | |
static void Main(string[] args) | |
{ | |
int n = int.Parse(Console.ReadLine()); | |
string[] numbers = Console.ReadLine().Split(new char[] { ',', ';', ' ' }, | |
StringSplitOptions.RemoveEmptyEntries); | |
bool stuckNums = false; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
class PythagoreanNumbers | |
{ | |
static void Main(string[] args) | |
{ | |
int n = int.Parse(Console.ReadLine()); | |
int[] nums=new int[n]; | |
bool pitagoreanEquation = false; | |
for (int i = 0; i < n; i++) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Text; | |
class PlusRemove | |
{ | |
static void Main(string[] args) | |
{ | |
//Judge mi dava 88/100 tochki | |
UTF8Encoding utf8 = new UTF8Encoding(); |