Numpy的tile()函数,就是将原矩阵横向、纵向地复制。tile是瓷砖的意思, 顾名思义,这个函数就是把数组像瓷砖一样铺展开来。 例1: 解释:b是一个数, 在同一个列表中把a横向铺展了21遍。 例2: 例3: 解释:相当于拓展至3行。 ...
分类:
编程语言 时间:
2019-11-09 12:13:30
阅读次数:
72
1 #include <iostream> 2 using namespace std; 3 4 typedef long long LL; 5 6 LL gcd(LL a, LL b) 7 { 8 if (!b) return a; 9 return gcd(b, a % b); 10 } 11 ...
分类:
其他好文 时间:
2019-11-09 00:27:42
阅读次数:
109
Ujan has been lazy lately, but now has decided to bring his yard to good shape. First, he decided to paint the path from his house to the gate. The pa ...
分类:
其他好文 时间:
2019-11-09 00:25:44
阅读次数:
99
题意:就是给你一个n,然后如果 n mod | i - j | == 0 并且 | i - j |>1 的话,那么i 和 j 就是同一种颜色,问你最大有多少种颜色? 思路: 比赛的时候,看到直接手推,发现有点东西,直接打表找出了规律 —— 如果 n的质因子只有一个,那么总数就是 那个 质因子。其它都 ...
分类:
其他好文 时间:
2019-11-07 19:13:59
阅读次数:
113
"题目链接" Sotuion Tile Painting 题目大意:给定一个长为$n$的序列,如果两个位置$i,j$满足$n \; mod \;|i j| =0 \;and\; |i j| \neq 1$的话这两个位置的颜色必须相同,问最多有多少种颜色 同余,中国剩余定理 分析: 假如$n$是一个质 ...
分类:
其他好文 时间:
2019-11-07 15:19:36
阅读次数:
122
T1 [数学] 期望得分:100 先通分,求出分子的最小公倍数,再讨论跟共同的分母B*D的关系即可。 【code】 #include<bits/stdc++.h> using namespace std; #define ll long long #define File "tile" inline ...
分类:
其他好文 时间:
2019-08-18 19:54:07
阅读次数:
77
There is a rectangular room, covered with square tiles. Each tile is colored either red or black. A man is standing on a black tile. From a tile, he c ...
分类:
其他好文 时间:
2019-07-25 00:55:44
阅读次数:
150
Description There is a rectangular room, covered with square tiles. Each tile is colored either red or black. A man is standing on a black tile. From ...
分类:
其他好文 时间:
2019-07-16 20:05:48
阅读次数:
148
[TOC] 参考资料: "quantized mesh 1.0 terrain format(用于三维可视化的流式海量地形数据集规范)" "Tile Map Service Specification" "国内主要地图瓦片坐标系定义及计算原理" "QuantizedMeshTerrainData" ...
分类:
其他好文 时间:
2019-06-25 00:11:56
阅读次数:
172
题目如下: You have a set of tiles, where each tile has one letter tiles[i]printed on it. Return the number of possible non-empty sequences of letters you ...
分类:
其他好文 时间:
2019-06-15 10:20:42
阅读次数:
117