Изменения рейтингов за последние раунды временно удалены. Скоро они будут возвращены. ×

Блог пользователя CopeCope

Автор CopeCope, история, 5 лет назад, По-английски

Given graph with $$$N$$$ vertices and there are $$$N*(N-1)/2$$$ edges, each one is either $$$(i,j)$$$ or $$$(j,i)$$$ for every $$$1<=i,j<=N$$$. How to prove or disprove that there is always a path of length $$$N-1$$$(edges) that visits every vertex once

Полный текст и комментарии »

  • Проголосовать: нравится
  • +15
  • Проголосовать: не нравится

Автор CopeCope, история, 5 лет назад, По-английски

Recently, Info Cup and Innopolis Open Final were held, and I participated in info cup and really liked the problems and also won a medal. I also qualified to Innopolis final but couldn't participate. Now, I really have a will to participate in some other competitions like these two. Does anyone know some other competitions for high school students like these two?
Thanks :)

Полный текст и комментарии »

  • Проголосовать: нравится
  • 0
  • Проголосовать: не нравится

Автор CopeCope, история, 5 лет назад, По-английски

Given array A of N <  = 500000 elements and each A[i] <  = N. Find number of partitions of array into some number of subsegments such that every subsegment has length greater or equal to minimum value of subsegment and smaller or equal to maximum value of subsegment.

Example:
A = {1, 6, 2, 3, 4, 3, 4}
Partitions are:
|1|6, 2, 3, 4, 3, 4|
|1, 6, 2|3, 4, 3, 4|
|1, 6, 2, 3|4, 3, 4|
|1|6, 2|3, 4, 3, 4|
|1|6, 2, 3|4, 3, 4|
|1, 6|2, 3|4, 3, 4|

How to solve this problem?

Полный текст и комментарии »

  • Проголосовать: нравится
  • +21
  • Проголосовать: не нравится

Автор CopeCope, история, 5 лет назад, По-английски

What happened with wcipeg wiki? Can't access any tutorial

Полный текст и комментарии »

  • Проголосовать: нравится
  • +7
  • Проголосовать: не нравится

Автор CopeCope, история, 6 лет назад, По-английски

Given N arrays of arbitrary length each, and M queries in form : a b. For each query output the number of arrays such that there exist Array[i] = a Array[j] = b and i < j (Basically, number of arrays such that a comes before b). Also, there can be any number of a's or b's in any array

N, M, a, b <  = 105 Consider that length of all arrays is  <  = 105

Example: Arrays
1 2 3 4
2 4
2 3 1 4

and queries are (1, 3) , (2, 4) , (1, 4) , (4, 1) answers are 1 , 3 , 2 , 0

Полный текст и комментарии »

  • Проголосовать: нравится
  • +9
  • Проголосовать: не нравится

Автор CopeCope, история, 6 лет назад, По-английски

Given array A of N (N <= 106 ) elements (Ai <= 109 ). Given Q queries (Q <= 106 ). Every query consist of number K (K <= 109 ). For every query find number of subsegments such that their maximum element is K.

Test case:
5
1 2 3 4 3
3
2
3
4
Output:
2 -> [2], [1,2]
4 -> [1,2,3], [2,3], [3], [3]
8 -> [1,2,3,4], [1,2,3,4,3], [2,3,4], [2,3,4,3], [3,4], [3,4,3], [4], [4,3]

Полный текст и комментарии »

  • Проголосовать: нравится
  • +9
  • Проголосовать: не нравится