Skip to content

Instantly share code, notes, and snippets.

View matthewpdias's full-sized avatar

Matthew Dias matthewpdias

View GitHub Profile
@wrunk
wrunk / jinja2_file_less.py
Last active September 19, 2023 15:05
python jinja2 examples
#!/usr/bin/env/python
#
# More of a reference of using jinaj2 without actual template files.
# This is great for a simple output transformation to standard out.
#
# Of course you will need to "sudo pip install jinja2" first!
#
# I like to refer to the following to remember how to use jinja2 :)
# http://jinja.pocoo.org/docs/templates/
#
@isabek
isabek / MatrixMultiplication.cpp
Last active October 19, 2023 08:55
Matrix multiplication strategies: ijk, ikj, jik, jki, kij, kji
#include <vector>
#include <cstdio>
#include <algorithm>
#include <ctime>
class Log {
public:
static void print(const char* strategy, long long int start, long long int end){
printf("%s: %f seconds\n", strategy, (double)(end - start) / 1000000);
}