Given a non-empty array of integers, return the k most frequent elements. Example 1: Input: nums = [1,1,1,2,2,3], k = 2 Output: [1,2] Example 2: Input ...
分类:
其他好文 时间:
2020-02-06 14:26:57
阅读次数:
65
原文链接 https://www.cnblogs.com/lomper/p/3960462.html 首先在头文件中包含 #include<QDebug> 当开发者需要为一个装置、文件、字符串或者控制台,写出调试和跟踪信息时,该类被使用。 在需要使用的地方插入: qDebug("intensity: ...
分类:
其他好文 时间:
2020-02-06 12:35:22
阅读次数:
84
Given a positive integer, output its complement number. The complement strategy is to flip the bits of its binary representation.給一個正整數,算出他的二補數 (2’s c... ...
分类:
编程语言 时间:
2020-02-06 12:32:52
阅读次数:
77
Given two binary search trees root1 and root2. Return a list containing all the integers from both trees sorted in ascending order. Example 1: Input: ...
分类:
其他好文 时间:
2020-02-06 10:51:59
阅读次数:
43
Given a matrix of M x N elements (M rows, N columns), return all elements of the matrix in diagonal order as shown in the below image. Example: Input: ...
分类:
其他好文 时间:
2020-02-06 10:46:38
阅读次数:
71
笔者测试环境VS2019。 基本介绍 原书作者引入Julia Sets意在使用GPU加速图形的绘制。Julia Set 是指满足下式迭代收敛的复数集合 $$ Z_{n+1}=Z_{n}^2+C $$ 环境配置 跑这个例子的主要困难应该在于配置环境。这个程序依赖于openGL中的glut库。由于VS2 ...
分类:
其他好文 时间:
2020-02-06 01:50:46
阅读次数:
71
java中的所说的线程池,一般都是围绕着 ThreadPoolExecutor 来展开的。其他的实现基本都是基于它,或者模仿它的。所以只要理解 ThreadPoolExecutor, 就相当于完全理解了线程池的精髓。 其实要理解一个东西,一般地,我们最好是要抱着自己的疑问或者理解去的。否则,往往收获 ...
分类:
编程语言 时间:
2020-02-06 01:45:37
阅读次数:
77
今天观看视频学习了ListView,学习了属性跟点击事件; 需要自己新建一个java继承BaseAdapter package com.example.yangy.myapplication1111111.ListView; import android.content.Context; impor ...
分类:
其他好文 时间:
2020-02-05 23:46:24
阅读次数:
115
1、字符串拼接 example:a = 'hello' , b = 'python' , c = '!' 将a,b ,c 中的字符串连成一句话。 第一种方法:用 + 号a + b +c 第二种方法:格式化字符串 %s'%s %s %s' % (a , b ,c) 第三种方法:''.join()方式, ...
分类:
编程语言 时间:
2020-02-05 23:40:18
阅读次数:
101
今天学习了数据的创建,以及关于数据库的相关操作。 今天主要是实现了对于数据库的增加和查找。 具体的代码如下: 首先是数据库的创建: DBOpenMessage.java package com.example.thetrueappwen; import android.content.Context ...
分类:
微信 时间:
2020-02-05 23:39:37
阅读次数:
112