Given an array of n positive integers and a positive integer s, find the minimal length of a contiguoussubarray of which the sum ≥ s. If there isn't o ...
分类:
编程语言 时间:
2019-02-10 12:29:27
阅读次数:
207
Description First we define: (1) $lcm(a,b)$, the least common multiple of two integers $a$ and $b$, is the smallest positive integer that is divisible ...
分类:
其他好文 时间:
2019-02-09 12:05:06
阅读次数:
158
Given two positive integers a and b, we can easily calculate the greatest common divisor (GCD) and the least common multiple (LCM) of a and b. But wha ...
分类:
其他好文 时间:
2019-02-09 12:00:20
阅读次数:
204
A.Slightly Decreasing Permutations Permutation p is an ordered set of integers p1, p2, ..., pn, consisting of n distinct positive integers, each of th ...
分类:
其他好文 时间:
2019-02-09 10:19:12
阅读次数:
141
https://pintia.cn/problem-sets/994805342720868352/problems/994805363117768704 This time your job is to fill a sequence of N positive integers into a s ...
分类:
其他好文 时间:
2019-02-08 11:54:38
阅读次数:
176
Given two rectangles and the coordinates of two points on the diagonals of each rectangle,you have to calculate the area of the intersected part of tw ...
分类:
其他好文 时间:
2019-02-08 01:09:14
阅读次数:
161
Suppose you have N integers from 1 to N. We define a beautiful arrangement as an array that is constructed by these N numbers successfully if one of t ...
分类:
其他好文 时间:
2019-02-06 23:54:15
阅读次数:
194
This problem was asked by Microsoft. A number is considered perfect if its digits sum up to exactly 10. Given a positive integer n, return the n-th pe ...
分类:
其他好文 时间:
2019-02-06 09:26:03
阅读次数:
187
题目地址 "题目链接" Description As we know, any positive integer C ( C = 2 ) can be written as the multiply of some prime numbers: C = p1×p2× p3× ... × pk whi ...
分类:
其他好文 时间:
2019-02-03 23:38:42
阅读次数:
214
https://pintia.cn/problem-sets/994805342720868352/problems/994805507225665536 Given a pair of positive integers, for example, 6 and 110, can this equa ...
分类:
其他好文 时间:
2019-02-03 21:01:13
阅读次数:
126