Skip to content

Instantly share code, notes, and snippets.

View skrolikowski's full-sized avatar
Coffee, Code & Cats

Shane Krolikowski skrolikowski

Coffee, Code & Cats
View GitHub Profile
@skrolikowski
skrolikowski / reverseInteger.py
Last active January 21, 2019 05:05
Reverse integer (Python)
def reverseInteger(val):
sign = -1 if val < 0 else 1
val = abs(val)
rev = 0
while val > 0:
num = val % 10
val = val // 10
rev = rev * 10 + num
@skrolikowski
skrolikowski / markdown
Created May 30, 2018 21:52
MinGW + SublimeText 3 + Google Test (Windows 10 x86)
### Download Cmake
Download the CMake `Windows win32-x86 Installer`:
https://cmake.org/download/
### Download latest Google Test release
Download latest release of Google Test:
https://github.com/google/googletest/releases
### Build for MinGW
After downloading Google Test navigate to the `src/` folder and use CMake to build the library files (I'm using [Git Bash](https://git-scm.com/downloads)):
@skrolikowski
skrolikowski / sublime-build
Created May 17, 2018 21:16
Love2D - Sublime Text 3 Build
{
"selector": "source.lua",
"file_regex": "^Error: (?:[^:]+: )?([^: ]+?):(\\d+):() ([^:]*)$",
"windows": {
"cmd": ["C:/Program Files/LOVE/love.exe", "${folder:${file_path}}"],
"shell": true
},
"osx": {
"cmd": ["/Applications/love.app/Contents/MacOS/love", "${file_path}"]
},
@skrolikowski
skrolikowski / sublime-build
Created May 17, 2018 21:14
Python v3 - Sublime Text 3 Build (Mac OS)
{
"cmd": ["python3", "-u", "$file"],
"file_regex": "^[ ]*File \"(...*?)\", line ([0-9]*)",
"selector": "source.python, source.py"
}