#include <stdio.h> int main (void) { signed short int a1;//有符号short unsigned short int a2;//无符号short signed int b1; unsigned int b2; signed long int c ...
分类:
编程语言 时间:
2021-05-24 08:09:05
阅读次数:
0
i++:先引用后加 ++I:先加后引用 示例代码: public static void main(String... args) { int a = 88; int c = a++; System.out.println(a); System.out.println(c); int b = 99; ...
分类:
其他好文 时间:
2021-05-24 08:08:47
阅读次数:
0
###双指针算法: 核心思想就是缩减时间复杂度 for (int i = 0; i < n; i++) { for (int j = 0; j < n; j++) { 时间复杂度是O(n * n) } } 双指针模板 for (i = 0; j = 0; j < n; j++) { while (j ...
分类:
其他好文 时间:
2021-05-24 08:01:14
阅读次数:
0
List接口 三大特点:1.有序的collection,2.有索引,3.允许存储重复元素 有序:存储与取出元素顺序是一致的 List接口中常用的方法 public void add (int index,E element) 将指定元素,添加到该集合中指定位置上 public E get(int i ...
分类:
编程语言 时间:
2021-05-24 07:55:05
阅读次数:
0
#引言 将两个已经排好序的数组进行合并,使得合并后的数组也是有序 示例: int a[] = {1, 3, 5, 11, 20}; int b[] = {1, 2, 3, 4, 7, 8, 11, 25, 30}; 排好序的结果 1 1 2 3 3 4 5 7 8 11 11 20 25 30 #代 ...
分类:
编程语言 时间:
2021-05-24 07:54:30
阅读次数:
0
在class 组件中,我们需要在 componentDidMounted 里面给 mp3 加上监听,然后在 组件销毁的时候 去掉监听。 来控制 mp3 的播放和暂停。相对来说比较麻烦。难以抽离。 这里用 hooks 达到完全抽离的效果: interface IAudioProps extends R ...
分类:
其他好文 时间:
2021-05-24 07:45:22
阅读次数:
0
可变参数 package com.luo.method; public class Demo4 { public static void main(String[] args) { Demo4 demo4 = new Demo4(); demo4.test(1, 2, 3, 4, 5); } pub ...
分类:
其他好文 时间:
2021-05-24 07:25:57
阅读次数:
0
1 参考《GMT 0009-2012 SM2密码算法使用规范》第6节“数据转换” 在utils.h和utils.c中完成位串与8位字节串的转换功能(10'): int Bitstr2ByteArr(unsigned char * bs, unsigned char * ba); int ByteAr ...
分类:
编程语言 时间:
2021-05-24 07:25:40
阅读次数:
0
1,存储类: 通过特定的字符来定义变量和函数可见性(作用域)和生命周期 1,auto存储类 auto 存储类是所有局部变量默认的存储类并只能修饰局部变量 例子: { int mount; 或 auto int month; } 2,register存储类 register 存储类用于定义存储在寄存器 ...
分类:
编程语言 时间:
2021-05-24 07:14:34
阅读次数:
0
Layout类中没有直接的swap方法,但是通过其他方法的组合就可以实现交换layout中控件的交换 1 QWidget *w1 = anibutton[1],*w2 = anibutton[3]; 2 int p1 = ui->horizontalLayout->indexOf(w1); 3 in ...
分类:
其他好文 时间:
2021-05-24 07:01:41
阅读次数:
0