Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View bosley's full-sized avatar
🏠
Working from home

bosley bosley

🏠
Working from home
View GitHub Profile
@bosley
bosley / fib.go
Last active September 16, 2020 20:08
package main
import (
"fmt"
)
// Calculate fib sequence
// This is done linerally as recursive calculation is an exponential explosion
// in time, and after the around 35th digit or so would be unreasonable to calculate
//
; ASM File for the Nabla VM
; https://github.com/NablaVM
; - This file utilizes the special functionality of functional units along
; side yield's reentry functionality as a POC
; for using them together as a memory storage unit
.file "memory_play"
.init main
@bosley
bosley / PubSub_with_ifs.cpp
Created April 2, 2020 17:14
A simple pubsub example using an interface in C++
#include <iostream>
#include <string>
#include <vector>
namespace {
// An interface for objects that want to 'be' subscribers
class SubscriberIf {
public:
#include <bitset>
#include <iostream>
void showXorOp() {
uint8_t var = 0xFF; // 255
uint8_t var1 = 0X0F; // 15
std::cout << (int)var << "\t" << std::bitset<8>(var) << std::endl;
@bosley
bosley / gist:4336d2be8908adc0da7e
Created July 19, 2015 15:53
Centos 7 Python3.3 Install
yum groupinstall "Development Tools" -y
yum install zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-devel readline-devel tk-devel gdbm-devel db4-devel libpcap-devel xz-devel -y
wget http://python.org/ftp/python/3.3.5/Python-3.3.5.tar.xz
tar xf Python-3.3.5.tar.xz
cd Python-3.3.5
./configure --prefix=/usr/local --enable-shared LDFLAGS="-Wl,-rpath /usr/local/lib"
make && make altinstall
wget https://bitbucket.org/pypa/setuptools/raw/bootstrap/ez_setup.py