Skip to content

Instantly share code, notes, and snippets.

View schesnowitz's full-sized avatar

Stephen Chesnowitz schesnowitz

View GitHub Profile
@schesnowitz
schesnowitz / SC Tech - YouTube Server.md
Created July 16, 2023 18:48
SC Tech - YouTube Server
@schesnowitz
schesnowitz / profile.json
Created May 14, 2023 07:17
profile.json
{
"public_identifier":"steve-chesnowitz",
"profile_pic_url":"None",
"background_cover_image_url":"None",
"first_name":"Stephen",
"last_name":"Chesnowitz",
"full_name":"Stephen Chesnowitz",
"follower_count":170,
"occupation":"Python Engineer at Halcyon",
"headline":"Python",
@schesnowitz
schesnowitz / regex.md
Created March 9, 2023 04:00
Overview using regex in python

Regular expressions are a powerful tool for working with text data in Python. They allow you to search for and manipulate patterns in strings, which can be useful for data cleaning, data extraction, and other text processing tasks.

In this article, we'll explore how to use regular expressions to extract data from strings in Python. We'll cover the basics of regular expressions, how to define a pattern, and how to use Python's re

@schesnowitz
schesnowitz / FToC.js
Created February 18, 2023 09:18
FToC.js
// f = (0 - 32) * 5 / 9
// console.log(f)
const getCelsius = (temp) => {
celsius = (temp - 32) * 5 / 9;
return celsius
};
@schesnowitz
schesnowitz / minMax.js
Created February 18, 2023 09:16
min max
const minMax = (someArray) => {
const min = Math.min(...someArray);
const max = Math.max(...someArray);
return {
min,
max
}
};
@schesnowitz
schesnowitz / object.js
Created February 18, 2023 07:24
Objects
let library = [
{
title: "Shithouse",
author: "Some Guy",
status: {
own: true,
reading: false,
read: false
}
},
@schesnowitz
schesnowitz / randomMath.js
Created February 17, 2023 23:10
random math generator
let x = Math.floor(Math.random() * 100 + 1);
let y = Math.floor(Math.random() * 50 + 1);
sum = (x + y).toString();
sumOutput = (`${x} + ${y} = ${sum}`);
remainder = (x % y).toString();
remainderOutput = (`${x} % ${y} = ${remainder}`);
product = (x * y).toString();
// SPDX-License-Identifier: MIT
pragma solidity >=0.4.22 <0.9.0;
contract Basic {
// General vars
uint public someNonSigned = 66;
// SPDX-License-Identifier: MIT
pragma solidity >=0.4.22 <0.9.0;
contract Basic {
// General vars
uint public someNonSigned = 66;
@schesnowitz
schesnowitz / contracts...Counter.sol
Created February 11, 2023 23:30
Created using remix-ide: Realtime Ethereum Contract Compiler and Runtime. Load this file by pasting this gists URL or ID at https://remix.ethereum.org/#version=soljson-v0.8.17+commit.8df45f5f.js&optimize=false&runs=200&gist=
// SPDX-License-Identifier: MIT
pragma solidity >= 0.7.0 < 0.9.0;
contract Counter {
uint count;
constructor() public {
count = 0;
}