<jupyter_start><jupyter_text>20-06-18: Daily Data Practice --- Daily Practices* Practice with DS/ML tools and processes  * [fast.ai course](https://course.fast.ai/)  * HackerRank SQL or Packt SQL Data Analytics  * Hands-on ML | NLP In Action | Dive Into Deep Learning | Coursera / guided projects    * Read, code along, take notes    * _test yourself on the concepts_ — i.e. do all the chapter exercises  * Try to hit benchmark accuracies with [UCI ML datasets](https://archive.ics.uci.edu/ml/index.php) or Kaggle* Meta Data: Review and write  * Focus on a topic, review notes and resources, write a blog post about it* 2-Hour Job Search* Interviewing  * Behavioral questions and scenarios  * Business case walk-throughs  * Hot-seat DS-related topics for recall practice (under pressure) --- Coding & Problem Solving Practice> Work through practice problems on HackerRank or similar  Python  [Staircase](https://www.hackerrank.com/challenges/staircase/problem)Consider a staircase of size $n = 4$:```      ```Observe that its base and height are both equal to $n$, and the image is drawn using `` symbols and spaces.  The last line is not preceded by any spaces.Write a program that prints a staircase of size $n$.<jupyter_code>def staircase(n):
    """Prints a staircase of size n."""
    pass
# === Test out initial idea === #
n = 4
for line in range(1, n + 1):
    # Make list of n octothorpes
    octo_list = ["#"] * line
    # Join string including n octothorpes
    print("".join(octo_list))

# This results in a descending staircase
# === Use right justified string method === #
n = 4
for line in range(1, n + 1):
    # Make list of n octothorpes
    octo_list = ["#"] * line
    # Join string including n octothorpes
    octo_line = "".join(octo_list)
    # Justify right
    octo_just = octo_line.rjust(n, " ")
    print(octo_just)
def staircase(n):
    """Prints a staircase of size n."""
    for line in range(1, n + 1):
        # Make list of n octothorpes
        octo_list = ["#"] * line
        # Join string including n octothorpes
        octo_line = "".join(octo_list)
        # Justify right
        octo_just = octo_line.rjust(n, " ")
        print(octo_just)

staircase(6)<jupyter_output>#
    ##
   ###
  ####
 #####
######
{'fraction_non_alphanumeric': 0.11224944320712694, 'fraction_numerical': 0.0075723830734966595, 'mean_word_length': 3.294455066921606, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 5, 'https://': 3, 'lorem ipsum': 0, 'www.': 1, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '651403', 'license': 'MIT', 'n_tokens_mistral': 720, 'n_tokens_neox': 688, 'n_words': 262, 'path': 'ds/practice/daily_practice/20-06/20-06-18-daily.ipynb', 'repo_name': 'tobias-fyi/vela', 'size': '2245'}