Skip to content

Collection of scripts corresponding to LucidProgramming YouTube tutorials

License

Notifications You must be signed in to change notification settings

Appledee/youtube_tutorials

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LucidProgramming YouTube Tutorial Scripts:

LucidProgramming is my YouTube channel and this repo consists of a collection of scripts corresponding to YouTube tutorials for my YouTube channel.

Contributing

I would love to compile solutions to all of the problems here, as well as offer solutions in different languages. Just create a pull request with your changes.

Index

Algorithms

Greedy Algorithms

Recursion

Search Algorithms

  • Binary Search
    Iterative and recursive implementation and comparison of binary search.

  • Python's Bisect Method
    We cover the "bisect" function in Python, and how this can be used to apply to problems requiring binary search.

  • Cyclic Sorted Array
    We use binary search to determine the first element of a sorted cyclically rotated list.

  • Find Bitonic Peak
    Determine what the "bitonic peak" of a sequence of numbers is using binary search.

  • Find Bitonic Peak
    Determine what the "bitonic peak" of a sequence of numbers is using binary search.

  • Find Closest Number
    Given an array of sorted integers. We need to find the closest value to the given number.

  • Find First Duplicate Entry
    Write a function that takes an array of sorted integers and a key and returns the index of the first occurrence of that key from the array.

  • Find Fixed Point
    Given an array of n distinct integers sorted in ascending order, write a function that returns a "fixed point" in the array. If there is not a fixed point return "None".

  • Integer Square Root
    Write a function that takes a non-negative integer and returns the largest integer whose square is less than or equal to the integer given.

Sorting Algorithms

String Processing

  • Convert Integer to String
    You are given some integer as input. Convert the integer you are given to a string. Do not make use of the built-in "str" function.

  • Convert String to Integer
    You are given some numeric string as input. Conver the string you are given to an integer. Do not make use of the built-in "int" function.

  • Is Anagram
    Given a string, determine if it is an anagram, i.e. a word or phrase formed by rearranging the letters of a different word or phrase.

  • Is Palindrome
    Given a string, determine if it is a palindrome, i.e. a word or phrase that can be read the same forwards and backwards.

  • Is Permutation
    Given two strings, determine if one string is a permutation of the other.

  • Is Palindrome Permutation
    Given a string, determine if it is a permutation of a palindrome.

  • Is Unique
    Implement an algorithm to determine if a string has all unique characters.

  • Look-and-Say Sequence
    Generate the so-called "Look-and-Say" sequence

  • Spreadsheet Decode
    Given a list of first/last name pairs, eliminate any entries with duplicate first names.

  • Spreadsheet Encode
    Given a column string as formatted in a spreadsheet program, write a function that returns a number corresponding to that particular column.

Bit Manipulation

  • Find Set Bit
    Given a number having only one "1" and all other "0"s in its binary representation, find position of set bit.

  • Is Even or Odd
    Write a program to determine if a given number is even or odd. Do not make use of the modulus operator.

  • Is Nth Bit Set
    Write a program that takes an integer and tests whether the n-th bit in the binary representation of that integer is set of not.

  • Is Power Two
    Given a positive integer, check if the integer is a power of 2.

  • Set Nth Bit
    Write a program that takes an integer and sets the n-th bit in the binary representation of that integer.

  • Toggle Nth Bit
    Write a program that takes an integer and toggles the n-th bit in the binary representation of that integer.

  • Unset Nth Bit
    Write a program that takes an integer and unsets the n-th bit in the binary representation of that integer.

  • Unset Right-Most Bit
    Write a program that takes an integer and unsets the right most bit in the binary representation of that integer

Data Science

Data Structures

Arrays

  • Arbitrary Precision Arithmetic
    Given two arrays that each represent an integer, compute the sum between these numbers.

  • Array Advance
    Given an array with integers that correspond to moves that can be made from left to right, determine if it is possible to advance to the end of the array.

  • Buy and Sell Stock Once
    Given a list of end-day stock prices, determine what the maximum profit one can make by buying and selling a single stock.

  • Two Sum
    Given an array of integers, return the two numbers such that they add up to a specific target.

Bloom Filter

Linked List

Singly Linked List
  • Count Occurrences
    Given a data element, determine how many nodes in a singly linked list contain this piece of data.

  • Deletion
    Given a data element, delete all nodes in a singly linked list that have this given data element.

  • Insertion
    Insert an element into a singly linked list.

  • Is Palindrome
    Given a singly linked list, determine if the data elements form a palindrome.

  • Length
    Given a singly linked list, calculate the length, i.e. the number of nodes in the linked list.

  • Merge Sorted
    Given two sorted singly linked lists, produce a merged singly linked list that is also sorted.

  • Nth-to-Last
    Given a singly linked list and an integer N, determine the Nth-to-last node in the list.

  • Remove Duplicates
    Given a singly linked list, remove all nodes with duplicate data elements.

  • Reverse
    Given a singly linked list, reverse the linked list.

  • Rotate
    Given a singly linked list and an integer, rotate the contents of the singly linked list.

  • Sum Two Lists
    Given two singly linked lists representing integers, produce a third singly linked list that represents the sum of these integers.

  • Swap Nodes
    Given a singly linked list and two nodes, swap the first node with the second.

  • Tail to Head
    Given a singly linked list swap the tail of the list with the head.

Circular Linked List
Doubly Linked List
  • Add Before/Add After
    Add a node in a doubly linked list before a given node. Add a node in a doubly linked list after a given node.

  • Append/Prepend
    Append (add to back) a node to a doubly linked list. Prepend (add to front) a node to a doubly linked list.

  • Delete
    Delete a node in a doubly linked list.

  • Insert
    Insert a node in a doubly linked list.

  • Pairs with Sum
    Obtain the pairs of nodes that sum up to a given target element.

  • Remove Duplicates
    Remove duplicates from a doubly linked list.

  • Reverse
    Reverse a doubly linked list.

Stack

  • Stack Implementation
    Impelementation and description of the stack data structure.

  • Balanced Parens
    Using the stack data structure, determine if a string of parentheses are properly balanced or not.

  • Divide by Two
    Perform division by two using the stack data structure.

  • Reverse String
    Reverse a string using the stack data structure.

Go

imgur Python

Multiprocessing and Threading

Natural Language Processing

Podcasts and Interviews

System Design

Technical Interview

  • Check if String has Unique Characters
    Write a script to determine if a given string has all unique characters.

  • Is Anagram
    Write a script to determine if a given string is an anagram.

  • Check if String is Permutation
    Given two strings, check if they are permutations of each other.

  • Check if String is Palindrome
    Given a string, check if it is a palindrome.

  • Two Sum Problem
    Given an array of integers, return indices of the two numbers such that they add up to a specific target. Each input would have exactly one solution, and don't use the same element twice.

  • Single Number Problem
    Given an array of integers, every element appears twice except for one. Find that single one.

  • FizzBuzz
    Solving the infamous "FizzBuzz" problem in Python.

  • Iterative and Recursive Factorial
    Calculate the factorial of a positive integer. Do so using both an iterative and recursive approach.

  • URLify String
    Write a method to replace all spaces in a string with '%20'. You may assume that the string has sufficient space at the end to hold the additional characters and that you are given the "true" length of the string.

  • One Away
    There are three types of edits that can be performed on strings: insert a character, remove a character, or replace a character. Given two strings, write a function to check if they are one edit (or zero edits) away.

  • Matrix Median
    We are given a row-wise sorted matrix of size r-by-c we need to find the median of the matrix given. It is assumed that r-by-c is always odd.

  • String Compression
    String Compression: Implement a method to perform basic string compression using the counts of repeated characters. For example, the string "aabcccccaaa" would become a2b1c5a3. If the "compressed" string would not become smaller than the original string, your method should return the original string. You can assume the string has only uppercase and lowercase letters (a-z).

  • String Rotation
    String Rotation: Given two strings, s1 and s2, write code to check if s2 is a rotation of s1 (e.g. "waterbottle" is a rotation of "erbottlewat").

  • Count Ones in Binary Representation
    Find the number of 1s in the binary representation of a number.

Twitter Python

Utility Scripts

Vim

Web Scraping and Automation

BeautifulSoup

PyAutoGui

Robobrowser

Scrapy

Selenium

About

Collection of scripts corresponding to LucidProgramming YouTube tutorials

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 83.8%
  • Jupyter Notebook 5.9%
  • Vim Script 5.8%
  • Go 4.5%