Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Code template regression & update #11

Merged
merged 1 commit into from
Apr 24, 2019
Merged

Code template regression & update #11

merged 1 commit into from
Apr 24, 2019

Conversation

Vigilans
Copy link

@Vigilans Vigilans commented Apr 23, 2019

Now:

  • "-c" uses codeonly.tpl and generates comment with metadata and [fid] name
  • "-cx" fallbacks to original behavior.

Examples:
"-c":

C:\Programs\nodejs\node.exe --inspect-brk=41626 bin\leetcode show 1 -c
/*
 * @lc app=leetcode id=1 lang=cpp
 *
 * [1] Two Sum
 */
class Solution {
public:
    vector<int> twoSum(vector<int>& nums, int target) {
        
    }
};

"-cx":

C:\Programs\nodejs\node.exe --inspect-brk=30942 bin\leetcode show 1 -cx
/*
 * @lc app=leetcode id=1 lang=cpp
 *
 * [1] Two Sum
 *
 * https://leetcode.com/problems/two-sum/description/
 *
 * algorithms
 * Easy (43.41%)
 * Likes:    10448
 * Dislikes: 345
 * Total Accepted:    1.7M
 * Total Submissions: 3.9M
 * Testcase Example:  '[2,7,11,15]\n9'
 *
 * Given an array of integers, return indices of the two numbers such that they
 * add up to a specific target.
 * 
 * You may assume that each input would have exactly one solution, and you may
 * not use the same element twice.
 * 
 * Example:
 * 
 * 
 * Given nums = [2, 7, 11, 15], target = 9,
 * 
 * Because nums[0] + nums[1] = 2 + 7 = 9,
 * return [0, 1].
 * 
 * 
 * 
 * 
 */
class Solution {
public:
    vector<int> twoSum(vector<int>& nums, int target) {
        
    }
};

@jdneo jdneo merged commit b9f0303 into master Apr 24, 2019
@jdneo jdneo deleted the vigilans/code-template branch April 24, 2019 11:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants