Skip to content

Instantly share code, notes, and snippets.

View gamesbrainiac's full-sized avatar
💭
Gone Fishing.

Nafiul Islam gamesbrainiac

💭
Gone Fishing.
View GitHub Profile
@gamesbrainiac
gamesbrainiac / orders.py
Created August 12, 2020 17:37
Has all the orders that is required for the third episode of "What does this package do?"
orders = [
{
"_id": {"$oid": "5bd761dcae323e45a93cd0b5"},
"customer": {
"gender": "M",
"age": 40,
"email": "[email protected]",
"satisfaction": 4
},
"items": [
@gamesbrainiac
gamesbrainiac / orders.py
Created August 12, 2020 17:37
Has all the orders that is required for the third episode of "What does this package do?"
orders = [
{
"_id": {"$oid": "5bd761dcae323e45a93cd0b5"},
"customer": {
"gender": "M",
"age": 40,
"email": "[email protected]",
"satisfaction": 4
},
"items": [
@gamesbrainiac
gamesbrainiac / fillout_ascii.py
Created May 22, 2024 19:49
ASCII Art Generator
from PIL import Image
class ASCIIArtGenerator:
def __init__(self, ascii_chars="@%#*+=-:. "):
"""
Initialize the generator with a string of ASCII characters.
The characters should range from darkest to lightest to visually represent different shades.
"""
# Initialize the ascii_chars attribute with the provided string of characters.
@gamesbrainiac
gamesbrainiac / fillout_ascii.rs
Last active May 22, 2024 20:09
ASCII Art Generator Rust
use image::{DynamicImage, GrayImage};
use std::path::Path;
struct ASCIIArtGeneratorRust {
ascii_chars: Vec<char>,
}
impl ASCIIArtGeneratorRust {
/// Constructs a new ASCIIArtGenerator with a given set of ASCII characters.
fn new(ascii_chars: &str) -> Self {