Skip to content

Commit 806c040

Browse files
authored
Updated exec time.
1 parent 2e5bb80 commit 806c040

File tree

11 files changed

+36
-35
lines changed

11 files changed

+36
-35
lines changed

README.md

Lines changed: 23 additions & 23 deletions
Large diffs are not rendered by default.

src.save/main/kotlin/g0001_0100/s0060_permutation_sequence/Solution.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
package g0001_0100.s0060_permutation_sequence
22

3-
// #Hard #Math #Recursion #2022_09_22_Time_293_ms_(27.78%)_Space_34.2_MB_(61.11%)
3+
// #Hard #Math #Recursion #2022_11_25_Time_146_ms_(100.00%)_Space_33.7_MB_(95.45%)
44

55
@Suppress("NAME_SHADOWING")
66
class Solution {

src.save/main/kotlin/g0001_0100/s0078_subsets/Solution.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ package g0001_0100.s0078_subsets
22

33
// #Medium #Top_100_Liked_Questions #Top_Interview_Questions #Array #Bit_Manipulation #Backtracking
44
// #Algorithm_II_Day_9_Recursion_Backtracking #Udemy_Backtracking/Recursion
5-
// #2022_09_01_Time_353_ms_(30.14%)_Space_36.4_MB_(91.78%)
5+
// #2022_11_25_Time_191_ms_(97.44%)_Space_36.1_MB_(96.15%)
66

77
class Solution {
88
fun subsets(nums: IntArray): List<List<Int>> {

src.save/main/kotlin/g0101_0200/s0101_symmetric_tree/Solution.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ package g0101_0200.s0101_symmetric_tree
22

33
// #Easy #Top_100_Liked_Questions #Top_Interview_Questions #Depth_First_Search #Breadth_First_Search
44
// #Tree #Binary_Tree #Data_Structure_I_Day_11_Tree #Level_2_Day_15_Tree
5-
// #2022_09_02_Time_290_ms_(26.98%)_Space_35.3_MB_(42.52%)
5+
// #2022_11_25_Time_190_ms_(91.36%)_Space_36.7_MB_(20.94%)
66

77
import com_github_leetcode.TreeNode
88

src.save/main/kotlin/g0101_0200/s0102_binary_tree_level_order_traversal/Solution.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ package g0101_0200.s0102_binary_tree_level_order_traversal
22

33
// #Medium #Top_100_Liked_Questions #Top_Interview_Questions #Breadth_First_Search #Tree
44
// #Binary_Tree #Data_Structure_I_Day_11_Tree #Level_1_Day_6_Tree #Udemy_Tree_Stack_Queue
5-
// #2022_09_02_Time_355_ms_(29.37%)_Space_36.7_MB_(63.47%)
5+
// #2022_11_25_Time_332_ms_(67.53%)_Space_37_MB_(56.24%)
66

77
import com_github_leetcode.TreeNode
88
import java.util.ArrayList

src.save/main/kotlin/g0101_0200/s0119_pascals_triangle_ii/Solution.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package g0101_0200.s0119_pascals_triangle_ii
22

33
// #Easy #Array #Dynamic_Programming #Data_Structure_II_Day_3_Array #Dynamic_Programming_I_Day_12
4-
// #Udemy_Dynamic_Programming #2022_10_08_Time_296_ms_(19.15%)_Space_34.1_MB_(92.20%)
4+
// #Udemy_Dynamic_Programming #2022_11_25_Time_157_ms_(97.27%)_Space_33.4_MB_(99.09%)
55

66
class Solution {
77
fun getRow(rowIndex: Int): List<Int> {

src.save/main/kotlin/g0101_0200/s0122_best_time_to_buy_and_sell_stock_ii/Solution.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package g0101_0200.s0122_best_time_to_buy_and_sell_stock_ii
22

33
// #Medium #Top_Interview_Questions #Array #Dynamic_Programming #Greedy #Dynamic_Programming_I_Day_7
4-
// #Udemy_Arrays #2022_10_08_Time_370_ms_(16.98%)_Space_39.2_MB_(53.51%)
4+
// #Udemy_Arrays #2022_11_25_Time_197_ms_(95.10%)_Space_35.3_MB_(96.33%)
55

66
class Solution {
77
fun maxProfit(prices: IntArray): Int {

src.save/main/kotlin/g0101_0200/s0129_sum_root_to_leaf_numbers/Solution.kt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package g0101_0200.s0129_sum_root_to_leaf_numbers
22

33
// #Medium #Depth_First_Search #Tree #Binary_Tree
4-
// #2022_10_08_Time_269_ms_(29.63%)_Space_33.9_MB_(90.74%)
4+
// #2022_11_25_Time_237_ms_(52.50%)_Space_34.1_MB_(55.00%)
55

66
import com_github_leetcode.TreeNode
77

@@ -17,6 +17,7 @@ import com_github_leetcode.TreeNode
1717
*/
1818
class Solution {
1919
private var sum = 0
20+
2021
fun sumNumbers(root: TreeNode): Int {
2122
recurseSum(root, 0)
2223
return sum

src.save/main/kotlin/g0101_0200/s0168_excel_sheet_column_title/Solution.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
package g0101_0200.s0168_excel_sheet_column_title
22

3-
// #Easy #String #Math #2022_10_11_Time_246_ms_(30.12%)_Space_33.6_MB_(75.90%)
3+
// #Easy #String #Math #2022_11_25_Time_208_ms_(66.07%)_Space_34.2_MB_(39.29%)
44

55
class Solution {
6-
fun convertToTitle(n: Int): String {
7-
var num = n
6+
fun convertToTitle(columnNumber: Int): String {
7+
var num = columnNumber
88
val sb = StringBuilder()
99
while (num != 0) {
1010
var remainder = num % 26

src.save/main/kotlin/g0101_0200/s0194_transpose_file/script.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Read from the file file.txt and print its transposed content to stdout.
2-
# #Medium #Shell #2022_10_18_Time_477_ms_(28.60%)_Space_3.9_MB_(33.97%)
2+
# #Medium #Shell #2022_11_25_Time_461_ms_(33.47%)_Space_3.9_MB_(34.89%)
33
wordcount=$(head -1 file.txt | wc -w)
44
col_n=1
55
while [[ $col_n -le $wordcount ]]; do

0 commit comments

Comments
 (0)