【文件属性】:
文件名称:icode:LeetCode,公司测试(Ali,Google等)等
文件大小:1.83MB
文件格式:ZIP
更新时间:2021-03-25 13:56:54
leetcode C++
编码
有一些用于算法的代码(包括C / C ++,Java,Python等),例如leetcode的解决方案
对于leetcode文件夹下的命名规则
.hpp文件是带有问题名称的名称,其空格由'_'代替。 而且,并且您的用户名被添加到文件名的末尾
如:
For the question "1. Two Sum"
The .hpp file is: "1_Two_Sum_username.hpp"
.hpp文件在第一行中添加“ #include” ../ base / icode.hpp”。 .hpp文件中的小节名称被命名为'L'+问题的ID,并继承了类“ icode”。 在类中重写run方法。
如:
#include "../base/icode.hpp"
class L1 : public icode {
...
void run() {
...