Skip to content

Instantly share code, notes, and snippets.

View Connicpu's full-sized avatar

Connie Hilarides Connicpu

View GitHub Profile
@Connicpu
Connicpu / charRange.lua
Created April 2, 2020 22:40
Idle Skilling script for auto-grinder
local function nextChar(state, curr)
if curr == nil then
return state[1]
end
local byte = string.byte(curr, 1)
if byte < state[2] then
return string.char(byte + 1)
end
end
@Connicpu
Connicpu / doathing.rs
Last active December 20, 2021 11:01
Poking a Rust vtable from C++
#![feature(box_syntax)]
pub struct MyThing {
stuff: Vec<i32>,
}
pub trait DoAThing {
fn add(&mut self, item: i32);
fn remove(&mut self) -> i32;
}
[EFFORT POST] Counter CIA Propaganda - A guide to the situation in Bolivia I put this together to counter the arguments I've been seeing most commonly with regard to the coup against Evo Morales in Bolivia. ###Claim 1: Evo packed the court full of loyalists so that he could become president for life In 2016, a referendum was held to establish whether Evo Morales would be able to run for re-election. He narrowly lost this referendum. Evo Morales agreed to abide by the results of the 2016 referendum preventing his candidacy for reelection until the Supreme Court reversed the decision. https://www.lostiempos.com/actualidad/pais/20171129/tribunal-constitucional-avala-reeleccion-indefinida-evo-morales Many western outlets have claimed that Evo Morales packed the court in order to hold onto power. However, this claim is questionable. The 2009 Bolivian constitution, approved by referendum, specifies the process by which a person is put on the Supreme Court. You can read the full constitution here: https://web.archiv
@Connicpu
Connicpu / main.cpp
Last active September 17, 2019 22:48
#include <rwlock.h>
#include <memory>
#include <stdio.h>
int main() {
RwLock<int> data{ 0 };
{
auto write = data.Write();
*write += 1;
use com_impl::{Refcount, VTable};
use winapi::ctypes::c_void;
use winapi::shared::winerror::{ERROR_INVALID_INDEX, HRESULT, HRESULT_FROM_WIN32, S_OK};
use winapi::um::dwrite::{IDWriteFontFileStream, IDWriteFontFileStreamVtbl};
use wio::com::ComPtr;
#[repr(C)]
#[derive(ComImpl)]
pub struct FileStream {
vtbl: VTable<IDWriteFontFileStreamVtbl>,
#[macro_use]
extern crate derive_com_impl;
extern crate com_impl;
extern crate winapi;
extern crate wio;
use com_impl::{Refcount, VTable};
use winapi::ctypes::c_void;
use winapi::shared::winerror::{ERROR_INVALID_INDEX, HRESULT, HRESULT_FROM_WIN32, S_OK};

Dragonsong

Instrumental Intro

B(+1) Bb(+1) G#(+1) F#(+1) G#(+1)
G#(+1) F#(+1) E(+1) C#(+1) Eb(+1) C#(+1)
B Bb B Eb(+1) C#(+1) Bb F# G#, G# Bb

An RSA Class Project Protocol

By Connie Hilarides

Overview

I have created a fairly simple protocol for encrypting and decrypting files so that we can all have a common system for encrypting and decrypting our files. This guide will not directly contain code because we are all using differeng languages and frameworks, but I will describe on an abstract level the process for reading and saving these files.

@Connicpu
Connicpu / keybase.md
Last active October 4, 2017 18:01
keybase.md

Keybase proof

I hereby claim:

  • I am connicpu on github.
  • I am connicpu (https://keybase.io/connicpu) on keybase.
  • I have a public key ASAmuRpW9K2pj2Zbb3vXvm18vw73i3CVFWW5UJaDoVWHrQo

To claim this, I am signing this object:

@Connicpu
Connicpu / main.rs
Created April 1, 2016 20:57
Performing work on mutable slices across two threads
extern crate crossbeam;
fn main() {
let n = 100;
let mut data: Vec<_> = (0..n).collect();
{
let (left, right) = data.split_at_mut(n / 2);
crossbeam::scope(|scope| {
scope.spawn(|| {