This commit is contained in:
Sainnhe Park 2022-03-12 11:04:49 +08:00
parent 9492097e79
commit e956e22e72
6 changed files with 8 additions and 8 deletions

View File

@ -1,5 +1,5 @@
#ifndef S1_TWO_SUM_HPP #ifndef S0001_TWO_SUM_HPP
#define S1_TWO_SUM_HPP #define S0001_TWO_SUM_HPP
#include <iostream> #include <iostream>
#include <unordered_map> #include <unordered_map>

View File

@ -1,5 +1,5 @@
#ifndef S2_ADD_TWO_NUMBERS_HPP #ifndef S0002_ADD_TWO_NUMBERS_HPP
#define S2_ADD_TWO_NUMBERS_HPP #define S0002_ADD_TWO_NUMBERS_HPP
struct ListNode { struct ListNode {
int val; int val;

View File

@ -1,4 +1,4 @@
#include "s1_two_sum.hpp" #include "s0001_two_sum.hpp"
using namespace std; using namespace std;
vector<int> Solution::twoSum(vector<int>& nums, int target) { vector<int> Solution::twoSum(vector<int>& nums, int target) {

View File

@ -1,4 +1,4 @@
#include "s2_add_two_numbers.hpp" #include "s0002_add_two_numbers.hpp"
ListNode* Solution::addTwoNumbers(ListNode* l1, ListNode* l2) { ListNode* Solution::addTwoNumbers(ListNode* l1, ListNode* l2) {
ListNode *l_begin = new ListNode((l1->val + l2->val) % 10); ListNode *l_begin = new ListNode((l1->val + l2->val) % 10);

View File

@ -1,4 +1,4 @@
#include "s1_two_sum.hpp" #include "s0001_two_sum.hpp"
#include <gtest/gtest.h> #include <gtest/gtest.h>
#include <vector> #include <vector>

View File

@ -1,4 +1,4 @@
#include "s2_add_two_numbers.hpp" #include "s0002_add_two_numbers.hpp"
#include <gtest/gtest.h> #include <gtest/gtest.h>