Files
LeetCode-Questions-CompanyWise/vmware_alltime.csv
Krishna Kumar Dey fb5f78b55e Chore: Add headers to all the files (#54)
## Description
- Add headers to all the CSV files

## Script used
```py
import csv
import os

# Set the path of the folder containing the CSV files
folder_path = "./LeetCode-Questions-CompanyWise"
headers = [
    "ID",
    "Title",
    "Acceptance",
    "Difficulty",
    "Frequency",
    "Leetcode Question Link",
]

# Loop through all the CSV files in the folder
for file_name in os.listdir(folder_path):
    if file_name.endswith(".csv"):
        # Read the CSV file into a list of rows
        file_path = os.path.join(folder_path, file_name)
        with open(file_path, "r") as f:
            reader = csv.reader(f)
            rows = list(reader)

        has_headers = False
        if len(rows) > 0 and rows[0] == headers:
            has_headers = True

        if not has_headers:
            rows.insert(0, headers)

            # Write the list of rows back to the CSV file
            with open(file_path, "w", newline="") as f:
                writer = csv.writer(f)
                writer.writerows(rows)

```
2023-04-01 11:07:49 +05:30

11 KiB

1IDTitleAcceptanceDifficultyFrequencyLeetcode Question Link
2146LRU Cache33.2%Medium0.40992460509770895https://leetcode.com/problems/lru-cache
3697Degree of an Array53.8%Easy0.3745732054339119https://leetcode.com/problems/degree-of-an-array
4460LFU Cache34.2%Hard0.3604069261652464https://leetcode.com/problems/lfu-cache
520Valid Parentheses39.0%Easy0.347758344150091https://leetcode.com/problems/valid-parentheses
637Sudoku Solver43.6%Hard0.33098179084516033https://leetcode.com/problems/sudoku-solver
749Group Anagrams56.9%Medium0.2956303911813633https://leetcode.com/problems/group-anagrams
84Median of Two Sorted Arrays29.6%Hard0.2749994072467641https://leetcode.com/problems/median-of-two-sorted-arrays
933Search in Rotated Sorted Array34.5%Medium0.2561733762253273https://leetcode.com/problems/search-in-rotated-sorted-array
101Two Sum45.6%Easy0.24761788734731766https://leetcode.com/problems/two-sum
1197Interleaving String31.5%Hard0.22582867117596545https://leetcode.com/problems/interleaving-string
1293Restore IP Addresses35.6%Medium0.21874266403522635https://leetcode.com/problems/restore-ip-addresses
131048Longest String Chain54.7%Medium0.21470136904554477https://leetcode.com/problems/longest-string-chain
1456Merge Intervals39.3%Medium0.20101852155261443https://leetcode.com/problems/merge-intervals
1575Sort Colors47.3%Medium0.1656671218888174https://leetcode.com/problems/sort-colors
1685Maximal Rectangle37.7%Hard0.15223129344145475https://leetcode.com/problems/maximal-rectangle
17221Maximal Square37.7%Medium0.1475288463816385https://leetcode.com/problems/maximal-square
1876Minimum Window Substring34.6%Hard0.14520312778609068https://leetcode.com/problems/minimum-window-substring
1923Merge k Sorted Lists40.2%Hard0.13640708740119573https://leetcode.com/problems/merge-k-sorted-lists
20322Coin Change35.5%Medium0.13572462473832947https://leetcode.com/problems/coin-change
211328Break a Palindrome43.3%Medium0.12838116664820678https://leetcode.com/problems/break-a-palindrome
22295Find Median from Data Stream44.3%Hard0.10502147513923703https://leetcode.com/problems/find-median-from-data-stream
23706Design HashMap61.3%Easy0.10482987091202353https://leetcode.com/problems/design-hashmap
242Add Two Numbers33.9%Medium0.10270361758692534https://leetcode.com/problems/add-two-numbers
25300Longest Increasing Subsequence42.6%Medium0.10155280044326445https://leetcode.com/problems/longest-increasing-subsequence
26609Find Duplicate File in System59.5%Medium0.09898183354885093https://leetcode.com/problems/find-duplicate-file-in-system
27733Flood Fill55.3%Easy0.09669362480247104https://leetcode.com/problems/flood-fill
28243Shortest Word Distance61.0%Easy0.08952296190665864https://leetcode.com/problems/shortest-word-distance
29981Time Based Key-Value Store53.1%Medium0.08621383525234454https://leetcode.com/problems/time-based-key-value-store
3047Permutations II46.4%Medium0.08386751759778556https://leetcode.com/problems/permutations-ii
31206Reverse Linked List62.5%Easy0.08096580890872224https://leetcode.com/problems/reverse-linked-list
3288Merge Sorted Array39.4%Easy0.0726641464118391https://leetcode.com/problems/merge-sorted-array
3317Letter Combinations of a Phone Number46.8%Medium0.06820582606617018https://leetcode.com/problems/letter-combinations-of-a-phone-number
345Longest Palindromic Substring29.5%Medium0.0667502613531191https://leetcode.com/problems/longest-palindromic-substring
35277Find the Celebrity41.8%Medium0.06562120535847293https://leetcode.com/problems/find-the-celebrity
36116Populating Next Right Pointers in Each Node45.2%Medium0.06417026482702023https://leetcode.com/problems/populating-next-right-pointers-in-each-node
373Longest Substring Without Repeating Characters30.4%Medium0.06370380162663494https://leetcode.com/problems/longest-substring-without-repeating-characters
3825Reverse Nodes in k-Group42.1%Hard0.062178154907672076https://leetcode.com/problems/reverse-nodes-in-k-group
39297Serialize and Deserialize Binary Tree47.5%Hard0.061960627359177074https://leetcode.com/problems/serialize-and-deserialize-binary-tree
408String to Integer (atoi)15.4%Medium0.0590196151944673https://leetcode.com/problems/string-to-integer-atoi
4141First Missing Positive32.0%Hard0.056273635982108605https://leetcode.com/problems/first-missing-positive
42426Convert Binary Search Tree to Sorted Doubly Linked List59.1%Medium0.05368014946362379https://leetcode.com/problems/convert-binary-search-tree-to-sorted-doubly-linked-list
43829Consecutive Numbers Sum37.5%Hard0.05341723749698583https://leetcode.com/problems/consecutive-numbers-sum
44186Reverse Words in a String II43.3%Medium0.05064373281875492https://leetcode.com/problems/reverse-words-in-a-string-ii
4546Permutations63.5%Medium0.05046375425919308https://leetcode.com/problems/permutations
4639Combination Sum56.1%Medium0.05030398316850793https://leetcode.com/problems/combination-sum
47269Alien Dictionary33.3%Hard0.04997917057465883https://leetcode.com/problems/alien-dictionary
48133Clone Graph34.8%Medium0.049801168649527466https://leetcode.com/problems/clone-graph
49238Product of Array Except Self60.1%Medium0.04711503937510501https://leetcode.com/problems/product-of-array-except-self
50698Partition to K Equal Sum Subsets45.0%Medium0.04685917114094188https://leetcode.com/problems/partition-to-k-equal-sum-subsets
51556Next Greater Element III31.7%Medium0.04679216150675895https://leetcode.com/problems/next-greater-element-iii
52215Kth Largest Element in an Array55.4%Medium0.04678657567912081https://leetcode.com/problems/kth-largest-element-in-an-array
5398Validate Binary Search Tree27.8%Medium0.046091107200267https://leetcode.com/problems/validate-binary-search-tree
54200Number of Islands46.8%Medium0.04526299408355752https://leetcode.com/problems/number-of-islands
55341Flatten Nested List Iterator52.9%Medium0.04440788848944038https://leetcode.com/problems/flatten-nested-list-iterator
56525Contiguous Array42.8%Medium0.04390949261556855https://leetcode.com/problems/contiguous-array
57121Best Time to Buy and Sell Stock50.5%Easy0.04215422741819192https://leetcode.com/problems/best-time-to-buy-and-sell-stock
58141Linked List Cycle41.1%Easy0.0419797805851107https://leetcode.com/problems/linked-list-cycle
5972Edit Distance44.8%Hard0.039482058697133414https://leetcode.com/problems/edit-distance
60380Insert Delete GetRandom O(1)47.5%Medium0.038717635350707984https://leetcode.com/problems/insert-delete-getrandom-o1
61905Sort Array By Parity74.1%Easy0.03787434929243582https://leetcode.com/problems/sort-array-by-parity
6221Merge Two Sorted Lists53.5%Easy0.03548634253021285https://leetcode.com/problems/merge-two-sorted-lists
63124Binary Tree Maximum Path Sum34.3%Hard0.034081815554754834https://leetcode.com/problems/binary-tree-maximum-path-sum
64150Evaluate Reverse Polish Notation36.3%Medium0.031526253646773944https://leetcode.com/problems/evaluate-reverse-polish-notation
65239Sliding Window Maximum43.0%Hard0.031228142547585713https://leetcode.com/problems/sliding-window-maximum
6655Jump Game34.6%Medium0.030985252381807864https://leetcode.com/problems/jump-game
6726Remove Duplicates from Sorted Array45.1%Easy0.030773138378062014https://leetcode.com/problems/remove-duplicates-from-sorted-array
68268Missing Number51.7%Easy0.03011913009547617https://leetcode.com/problems/missing-number
6962Unique Paths54.1%Medium0.02853749186115581https://leetcode.com/problems/unique-paths
7011Container With Most Water50.8%Medium0.02727648457622222https://leetcode.com/problems/container-with-most-water
71153Sum26.8%Medium0.02661031301111795https://leetcode.com/problems/3sum
72162Find Peak Element43.3%Medium0.02516251642407408https://leetcode.com/problems/find-peak-element
73139Word Break40.1%Medium0.024095228922591846https://leetcode.com/problems/word-break
74127Word Ladder29.6%Medium0.023704813655166343https://leetcode.com/problems/word-ladder
75647Palindromic Substrings60.6%Medium0.023250853650202817https://leetcode.com/problems/palindromic-substrings
761209Remove All Adjacent Duplicates in String II56.9%Medium0.02324334737232728https://leetcode.com/problems/remove-all-adjacent-duplicates-in-string-ii
77102Binary Tree Level Order Traversal54.6%Medium0.02252956425342345https://leetcode.com/problems/binary-tree-level-order-traversal
78113Path Sum II46.7%Medium0.021882711249507664https://leetcode.com/problems/path-sum-ii
7963Unique Paths II34.6%Medium0.01949801804099658https://leetcode.com/problems/unique-paths-ii
80402Remove K Digits28.4%Medium0.016863806052004816https://leetcode.com/problems/remove-k-digits
81977Squares of a Sorted Array72.1%Easy0.015474196582597383https://leetcode.com/problems/squares-of-a-sorted-array
8280Remove Duplicates from Sorted Array II44.0%Medium0.014815085785140639https://leetcode.com/problems/remove-duplicates-from-sorted-array-ii
83109Convert Sorted List to Binary Search Tree47.7%Medium0.014440684154794336https://leetcode.com/problems/convert-sorted-list-to-binary-search-tree
84230Kth Smallest Element in a BST60.2%Medium0.014200301729123736https://leetcode.com/problems/kth-smallest-element-in-a-bst
85304Range Sum Query 2D - Immutable38.6%Medium0.013913267916985026https://leetcode.com/problems/range-sum-query-2d-immutable
86101Symmetric Tree46.8%Easy0.013553786479814183https://leetcode.com/problems/symmetric-tree
87226Invert Binary Tree65.0%Easy0.01235091863400913https://leetcode.com/problems/invert-binary-tree
88287Find the Duplicate Number55.5%Medium0.012335682739188652https://leetcode.com/problems/find-the-duplicate-number
89234Palindrome Linked List39.3%Easy0.010171877938733932https://leetcode.com/problems/palindrome-linked-list
9028Implement strStr()34.5%Easy0.008850485542574548https://leetcode.com/problems/implement-strstr
9150Pow(x;n)30.3%Medium0.008728496167158806https://leetcode.com/problems/powx-n
92416Partition Equal Subset Sum43.7%Medium0.008686265255960345https://leetcode.com/problems/partition-equal-subset-sum
93394Decode String50.0%Medium0.008166644000272283https://leetcode.com/problems/decode-string
94163Sum Closest46.0%Medium0.0075259057003469075https://leetcode.com/problems/3sum-closest
95692Top K Frequent Words51.8%Medium0.007516006820935329https://leetcode.com/problems/top-k-frequent-words
9636Valid Sudoku48.7%Medium0.007258242715805398https://leetcode.com/problems/valid-sudoku
9719Remove Nth Node From End of List35.2%Medium0.0069087555063702365https://leetcode.com/problems/remove-nth-node-from-end-of-list
98151Reverse Words in a String21.9%Medium0.0061359296669270605https://leetcode.com/problems/reverse-words-in-a-string
99199Binary Tree Right Side View54.1%Medium0.0056826406650506926https://leetcode.com/problems/binary-tree-right-side-view
100621Task Scheduler50.1%Medium0.005261323957171611https://leetcode.com/problems/task-scheduler
101153Find Minimum in Rotated Sorted Array45.1%Medium0.0037558729598054378https://leetcode.com/problems/find-minimum-in-rotated-sorted-array
102347Top K Frequent Elements61.2%Medium0.0033396446491217604https://leetcode.com/problems/top-k-frequent-elements
10379Word Search35.6%Medium0.0016647248725526849https://leetcode.com/problems/word-search