Title: Creating a new CSV
Description: CSVs are a great way to store data. With the CSV package, writing to csvs is made extremely simple. Personally, I like to have the data stored in the form of a list, and each list is representative of a row. However, you can work with dictionaries as well. Therefore, a full csv will be merely a list of lists. There are a ton of things you can do with the CSV package, look here for more information.
Title: Adding data to an existing CSV
Description: In the previous tip, we created a CSV, but what if we want to append new data to a csv? The process is very similiar to creating a new csv, but with a few slight differences.
Title: Reading a CSV
Description: Deciphering data stored in a CSV can be time consuming by hand, but reading one with Python can be very efficient. You can easily find the number of rows and column, perform analysis and a lot more.
Title: Get your computer name and ip
Description: Using python's standard library package, socket, you can easily obtain the computer's name and ip.
Title: Find files in a directory by last modified
Description: Using Python's standard library package, os, find all the files in a specific directory and return them based on what was last modified.
Title: OS path stuff
Description: Using python's standard library package, os, you can manipulate directory and file paths to get information. Extremely useful when dealing with relative paths.
Title: Temporarily append a Python package to your Python path
Description: If you are working with a large Python package project that has modules that need to import modules above it in the directory, you may want to temporarily append the root folder to your Python path. This way you can first import the folder, and then a Python module underneath it. You can easily do this using Python package os, and sys and a one-liner that you want to put in the main file that is ran.
Title: One liners
Description: Sometimes you just want your code more compact, here are a few tips to do just that in the form of function returns. The first function will be a multi-line function and the second one will be the same function result in one-line form.