Presented by UCLA ACM ICPC
Event Details: https://tinyurl.com/cs32-icpc
Questions: https://tinyurl.com/ask-ucla-icpc
ICPC Facebook Group: https://www.facebook.com/groups/ucla.icpc/
Feedback Survey: https://forms.gle/JJAmgrR93vtdSURy7
- Workshop 1 (Week 2): Introduction to Technical Interviews
- Workshop 2 (Week 3): Linked Lists
- Workshop 3 (Week 5): Stacks and Queues
- Workshop 4 (Week 6): Recursion
- Workshop 5 (Week 7): Big-O and STLs
- Workshop 6 (Week 8):
Trees and Binary SearchNo meeting this week Winter 2020 - Workshop 7 (Week 9): Trees and Hash Tables
Slides: https://docs.google.com/presentation/d/1SEaFGIBbvp7M_9ow1_6bcuTDRzenfgPmmCLPLU3_hAc/edit?usp=sharing
Warmup Problem: Fizz Buzz
- Leetcode Problem 412: https://leetcode.com/problems/fizz-buzz/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop1_Introduction/Warmup_Fizz%20Buzz_412.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop1_Introduction/Warmup_Fizz%20Buzz_412.py
Problem 1: Power of Two
- Leetcode Problem 231: https://leetcode.com/problems/power-of-two/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop1_Introduction/Problem1_Power%20of%20Two_231.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop1_Introduction/Problem1_Power%20of%20Two_231.py
Problem 2: Remove Vowels from a String
- Leetcode Problem 1119: https://leetcode.com/problems/remove-vowels-from-a-string/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop1_Introduction/Problem2_Remove%20Vowels%20from%20a%20String_1119.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop1_Introduction/Problem2_Remove%20Vowels%20from%20a%20String_1119.py
Problem 3: Robot Return to Origin
- Leetcode Problem 657: https://leetcode.com/problems/robot-return-to-origin/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop1_Introduction/Problem3_Robot%20Return%20to%20Origin_657.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop1_Introduction/Problem3_Robot%20Return%20to%20Origin_657.py
Problem 4: To Lower Case
- Leetcode Problem 709: https://leetcode.com/problems/to-lower-case/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop1_Introduction/Problem4_To%20Lower%20Case_709.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop1_Introduction/Problem4_To%20Lower%20Case_709.py
Additional Problems:
- Leetcode Problem 344: https://leetcode.com/problems/reverse-string/
- Leetcode Problem 283: https://leetcode.com/problems/move-zeroes/
- Leetcode Problem 7: https://leetcode.com/problems/reverse-integer/
- Leetcode Problem 66: https://leetcode.com/problems/plus-one/
Slides: https://docs.google.com/presentation/d/1JLyHwHtVZiEKCivv0K1txKbsF-P8bZCe8CkCZjhHiAM/edit
Warmup Problem: Delete Node in a Linked List
- Leetcode Problem 237: https://leetcode.com/problems/delete-node-in-a-linked-list/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop2_Linked%20Lists/Warmup_.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop2_Linked%20Lists/Warmup_.py
Problem 1: Middle of the Linked List
- Leetcode Problem 876: https://leetcode.com/problems/middle-of-the-linked-list
- C++ Solution:
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop2_Linked%20Lists/Problem1_Middle_of_Linked_Lists.py
Problem 2: Reverse Linked List
- Leetcode Problem 206: https://leetcode.com/problems/reverse-linked-list
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop2_Linked%20Lists/Problem2_Reverse%20Linked%20List.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop2_Linked%20Lists/Problem2_Reverse_Linked_Lists.py
Problem 3: Merge Two Sorted Lists
- Leetcode Problem 21: https://leetcode.com/problems/merge-two-sorted-lists/
- C++ Solution:
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop2_Linked%20Lists/Problem3_Merge_Two_Sorted_Lists.py
Problem 4: Linked List Cycle
- Leetcode Problem 141: https://leetcode.com/problems/linked-list-cycle
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop2_Linked%20Lists/Problem1_Linked%20List%20Cycle.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop2_Linked%20Lists/Problem4_LinkedListCycle.py
Bonus Problem: Intersection of Two Linked Lists
- Leetcode Problem 160: https://leetcode.com/problems/intersection-of-two-linked-lists
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop2_Linked%20Lists/Problem3_Intersection%20of%20Two%20Linked%20Lists
- Python Solution:
Additional Problems:
- Leetcode Problem 83: https://leetcode.com/problems/remove-duplicates-from-sorted-list
- Leetcode Problem 203: https://leetcode.com/problems/remove-linked-list-elements/
- Leetcode Problem 1290: https://leetcode.com/problems/convert-binary-number-in-a-linked-list-to-integer
- Leetcode Problem 234: https://leetcode.com/problems/palindrome-linked-list
Slides: https://docs.google.com/presentation/d/1T6h2FOzrU48AzzI5K8gE9X0Rk7FPJTT6EUKUByBMgpw/edit?usp=sharing
Warmup Problem: Valid Parentheses
- Leetcode Problem 20: https://leetcode.com/problems/valid-parentheses/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop3_Stacks%20%2B%20Queues/Warmup_Valid%20Parentheses_20.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop3_Stacks%20%2B%20Queues/Warmup_Valid%20Parentheses_20.py
Problem 1: Backspace String Compare
- Leetcode Problem 844: https://leetcode.com/problems/backspace-string-compare/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop3_Stacks%20%2B%20Queues/Problem1_Backspace%20String%20Compare_844.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop3_Stacks%20%2B%20Queues/Problem1_Backspace%20String%20Compare_844.py
Problem 2: Implement Stack Using Queues
- Leetcode Problem 225: https://leetcode.com/problems/implement-stack-using-queues/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop3_Stacks%20%2B%20Queues/Problem2_Implement%20Stack%20Using%20Queues_255.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop3_Stacks%20%2B%20Queues/Problem2_Implement%20Stack%20Using%20Queues_255.py
Problem 3: Evaluate Postfix Expressions
- Geeks for Geeks Problem: https://www.geeksforgeeks.org/stack-set-4-evaluation-postfix-expression/
- CS 32 Solution: https://docs.google.com/presentation/d/1gMBk2Km7qNUcvF-4pSBIyK-ynjQbHsQv/edit#slide=id.p16
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop3_Stacks%20%2B%20Queues/Problem3_Evaluate%20Postfix%20Expressions.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop3_Stacks%20%2B%20Queues/Problem3_Evaluate%20Postfix%20Expressions.py
Problem 4: Remove Outermost Parentheses
- Leetcode Problem 1021: https://leetcode.com/problems/remove-outermost-parentheses/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop3_Stacks%20%2B%20Queues/Problem3_Evaluate%20Postfix%20Expressions.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop3_Stacks%20%2B%20Queues/Problem4_Remove%20Outermost%20Parentheses_1021.py
Slides: https://docs.google.com/presentation/d/1Cs-cDp8teGPEopOy-AiCJJ7pDy4U2L6SyRBh_K_3-BI/edit?usp=sharing
Warmup Problem: Factorial
- Geeks for Geeks problem: https://www.geeksforgeeks.org/program-for-factorial-of-a-number/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop4_Recursion/Warmup_.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop4_Recursion/Warmup_.py
Problem 1: Sum Of Array Of Numbers Using Recursion.
- Geeks for Geeks: https://www.geeksforgeeks.org/sum-array-elements-using-recursion/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop4_Recursion/problem1_sum_of_array_of_numbers.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop4_Recursion/problem1_sum_of_array_of_numbers.py
Problem 2: Group Integers
- CodingBat: https://codingbat.com/prob/p145416
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop4_Recursion/problem2_group_integers.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop4_Recursion/problem2_group_integers.py
Problem 3: Climbing Stairs.
- Leetcode: https://leetcode.com/problems/climbing-stairs/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop4_Recursion/problem3_climbing_stairs.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop4_Recursion/problem3_climbing_stairs.py
Problem 4: Letter Combinations.
- Leetcode Problem 17: https://leetcode.com/problems/letter-combinations-of-a-phone-number/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop4_Recursion/problem4_letter_combinations.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop4_Recursion/problem4_letter_combinations.py
Slides: https://docs.google.com/presentation/d/1j1nIrwrgjOxo5cS73hW8agERTAz2f7qLRAjSZE88MNg/edit#slide=id.g7e66b61697_1_24 Kahoot: https://play.kahoot.it/v2/lobby?quizId=e7d7d6ba-b368-41fa-8fc9-3c41f950ee29
Problem 1: Valid Anagram
- Leetcode Problem 242: https://leetcode.com/problems/valid-anagram/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop5_BigO/Problem1_Valid_Anagram.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop5_BigO/Problem1_Valid_Anagram.py
Problem 2: Missing Number
- Leetcode Problem 268: https://leetcode.com/problems/missing-number/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop5_BigO/Problem2_Missing_Number.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop5_BigO/Problem2_Missing_Number.py
Problem 3: Add Digits
- Leetcode Problem 258: https://leetcode.com/problems/add-digits/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop5_BigO/Problem3_Add_Digits.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop5_BigO/Problem3_Add_Digits.py
Problem 4: Find Peak Element
- Leetcode Problem 162: https://leetcode.com/problems/find-peak-element/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop5_BigO/Problem4_Find_Peak_Element.cpp
- Python Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop5_BigO/Problem4_Find_Peak_Element.py
Slides: https://docs.google.com/presentation/d/1jknXhuq3UFEp7bR-nkYsR8GbIeF1UHBmoN3rTohBTc0/edit?usp=sharing
Problem 1: Sum of Left Leaves
- Leetcode Problem 404: https://leetcode.com/problems/sum-of-left-leaves/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop6_Trees%20%2B%20Hash%20Tables/Problem1_Sum%20of%20Left%20Leaves_404.cpp
- Python Solution:https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop6_Trees%20%2B%20Hash%20Tables/Problem1_Sum_of_Left_Leaves_404.py
Problem 2: Path Sum
- Leetcode Problem 112: https://leetcode.com/problems/path-sum/
- C++ Solution:https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop6_Trees%20%2B%20Hash%20Tables/Problem2_Path%20Sum_112.cpp
- Python Solution:https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop6_Trees%20%2B%20Hash%20Tables/Problem2_Path_Sum_112.py
Problem 3: Two Sum
- Leetcode Problem 1: https://leetcode.com/problems/two-sum/
- C++ Solution:https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop6_Trees%20%2B%20Hash%20Tables/Problem3_Two%20Sum_1.cpp
- Python Solution:https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop6_Trees%20%2B%20Hash%20Tables/Problem3_Two%20Sum_1.py
Problem 4: Intersection of Two Arrays
- Leetcode Problem 349: https://leetcode.com/problems/intersection-of-two-arrays/
- C++ Solution: https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop6_Trees%20%2B%20Hash%20Tables/Problem4_Intersection%20of%20Two%20Arrays_349.cpp
- Python Solution:https://github.com/uclaacm/cs32-interview-prep20/blob/master/Workshop6_Trees%20%2B%20Hash%20Tables/Problem4_Intersection%20of%20Two%20Arrays_349.py