x&&y&&z<0 -> x<0 && y<0 &&z<0
x||y||z==0 -> x==0 || y==0 || z==0
...
sum(i.count)
from sales
join (
select sale_id, count(*) count from sale_items
) i on (i.sale_id = sales.id)
group by DATE(event_date);
s = 0
for i in range(0, n):
p = 1
for j in range(1, m+1):
p *= a[i* m+j]
s += p
1) На e-mail номер телефона приходит без знака "+" перед цифрой "7".
params.push(elems[i].name + '=' + encodeURIComponent(elems[i].value));
2) При отправке формы Chrome выдаёт в консоль 2 ошибки: Refused to set unsafe header "Content-length" и Refused to set unsafe header "Connection".
... ORDER BY col + 0 DESC
... ORDER BY CAST(col AS int) DESC
...
public function __get($name) {
if ($name == "fio") return "{$this->firstName} {$this->lastName}";
throw Exception("invalid property: {$name}");
}
<img src="cid:20161010_dailykpisnapshot_OCuZ4O4.png"
, а сами изображения, как аттачменты с заголовками типа: Content-Type: image/png
Content-Disposition: inline
Content-Transfer-Encoding: base64
Content-ID: <20161010_dailykpisnapshot_OCuZ4O4.png>
import math
def npr(k):
x = 2*k*math.log(k)
xp = 1
while abs(x/xp-1) > 0.001:
xp = x
x = x - (x - k*math.log(x)) * math.log(x) / (math.log(x) - 1)
return x
def rwh_primes(n):
sieve = [True] * n
for i in range(3,int(n**0.5)+1,2):
if sieve[i]:
sieve[i*i::2*i]=[False]*((n-i*i-1)//(2*i)+1)
return [2] + [i for i in range(3,n,2) if sieve[i]]
k = int(input())
print( rwh_primes( int(npr(k)) + 1 )[k-1] )
SELECT DATE(timestamp), AVG(value) ...
FROM table
GROUP BY DATE(timestamp)