This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// We can use stl container list as a double | |
// ended queue to store the cache keys, with | |
// the descending time of reference from front | |
// to back and a set container to check presence | |
// of a key. But to fetch the address of the key | |
// in the list using find(), it takes O(N) time. | |
// This can be optimized by storing a reference | |
// (iterator) to each key in a hash map. | |
#include <bits/stdc++.h> | |
using namespace std; |
A clean installation of Ubuntu 18.04.02 LTS was used.
This gist is an extension to the official docs, adding missing parts and instructions.
follow the pre-installation actions on:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
### steps #### | |
# Verify the system has a cuda-capable gpu | |
# Download and install the nvidia cuda toolkit and cudnn | |
# Setup environmental variables | |
# Verify the installation | |
### | |
### to verify your gpu is cuda enable check |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"version":1,"resource":"file:///d%3A/Projects/axinan/b2c-id-web/src/__tests__/utils/common.test.ts","entries":[{"id":"rA8e.ts","source":"Workspace Edit","timestamp":1665658837123},{"id":"46ZA.ts","timestamp":1665658853345},{"id":"uFXv.ts","source":"Workspace Edit","timestamp":1666185864781}]} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from flask import Flask, render_template | |
from flask_paginate import Pagination, get_page_args | |
app = Flask(__name__) | |
app.template_folder = '' | |
users = list(range(100)) | |
def get_users(offset=0, per_page=10): |
With the introduction of GitHub's Squash and Merge feature, this has become less prevelant, however it's still useful in scenarios where GitHub's interface is unavailable.
Let's talk through two ways to do a squash and merge on the command line.
When to use it
- When you have not merged main into your feature branch
- There are no merge conflicts
Github repo for the Course: Stanford Machine Learning (Coursera)
Quiz Needs to be viewed here at the repo (because the image solutions cant be viewed as part of a gist)
True or False | Statement | Explanation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<style type="text/css"> | |
#chart text { | |
fill: black; | |
font: 10px sans-serif; | |
text-anchor: end; | |
} | |
.axis text { | |
font: 10px sans-serif; |
$ curl https://sdk.cloud.google.com | bash
When the first time you run the above statement, it might be that you'll get the following error if python2 is not installed in your system.
Welcome to the Google Cloud SDK!
Traceback (most recent call last):
File "/home/pratos/google-cloud-sdk/lib/third_party/enum/__init__.py", line 364, in __getattr__
NewerOlder