上一页 1 2 3 4 5 6 7 8 9 ··· 79 下一页
摘要: /** * 575. Distribute Candies * https://leetcode.com/problems/distribute-candies/description/ * Alice has n candies, where the ith candy is of type ca 阅读全文
posted @ 2023-01-25 00:56 johnny_zhao 阅读(32) 评论(0) 推荐(0) 编辑
摘要: /** * 552. Student Attendance Record II * https://leetcode.com/problems/student-attendance-record-ii/ * An attendance record for a student can be repr 阅读全文
posted @ 2023-01-24 15:26 johnny_zhao 阅读(14) 评论(0) 推荐(0) 编辑
摘要: /** * 551. Student Attendance Record I * You are given a string s representing an attendance record for a student where each character signifies wheth 阅读全文
posted @ 2023-01-22 00:27 johnny_zhao 阅读(17) 评论(0) 推荐(0) 编辑
摘要: 常量指针: const在*之前 指针的地址是可以被再次赋值的(可以修改的) 指针地址上面的值(变量)是不能被修改的 常量指针的常量是不能被改变的 指针常量: const在*之后 指针的地址是不可以被再次赋值的(不可以修改的) 指针地址上面的值(变量)是能被修改的 指针常量的指针地址是不能被改变的 i 阅读全文
posted @ 2023-01-11 01:09 johnny_zhao 阅读(12) 评论(0) 推荐(0) 编辑
摘要: #include <iostream> using namespace std; class Shape { protected: int width; int height; string name; public: // pure virtial function for interface v 阅读全文
posted @ 2023-01-08 16:10 johnny_zhao 阅读(20) 评论(0) 推荐(0) 编辑
摘要: virtual在类中使用 如在多继承中(环状继承): class D{......}; class B: public D{......}; class A: public D{......}; class C: public B, public A{.....}; 这个继承会使D创建两个对象,要解 阅读全文
posted @ 2023-01-08 13:27 johnny_zhao 阅读(52) 评论(0) 推荐(0) 编辑
摘要: 指针:从本质上是存放变量地址的变量,在逻辑上是独立的,它可以被改变,包括其所指向的地址的改变和其指向的地址中所存放的数据的改变。 引用:是一个别名,它在逻辑上不是独立的,它的存在有依附性,所以引用必须在一开始就被初始化,而且引用的对象在其整个生命周期中是不能被改变的(自始至终只能依附于同一个变量)。 阅读全文
posted @ 2023-01-06 21:55 johnny_zhao 阅读(9) 评论(0) 推荐(0) 编辑
摘要: GetMethodID中sig参数是对函数的签名,也可以说标识,具体的格式为:(函数参数)返回值。 方法签名中用大写的字母对应了java的基本数据类型: Z -> boolean B -> byte C -> char S -> short I -> int J -> long F -> float 阅读全文
posted @ 2023-01-05 20:33 johnny_zhao 阅读(391) 评论(0) 推荐(0) 编辑
摘要: https://blog.csdn.net/weixin_45774350/article/details/123135372 阅读全文
posted @ 2023-01-04 21:37 johnny_zhao 阅读(34) 评论(0) 推荐(0) 编辑
摘要: 题目在这里 pub fn prefix_matches(prefix: &str, request_path: &str) -> bool { //split by slash and change element into Option and add None at the end. let m 阅读全文
posted @ 2022-12-25 23:08 johnny_zhao 阅读(32) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 9 ··· 79 下一页