Skip to content

Instantly share code, notes, and snippets.

View ehzawad's full-sized avatar
🎃
Wasteland Baby!

Emrul Hasan Zawad ehzawad

🎃
Wasteland Baby!
View GitHub Profile
@ehzawad
ehzawad / calenderto_bangla.py
Created October 16, 2023 09:01
calender_to_bangla
from enum import Enum
import calendar
class BengaliMonths(Enum):
January = 'জানুয়ারী'
February = 'ফেব্রুয়ারী'
March = 'মার্চ'
April = 'এপ্রিল'
May = 'মে'
June = 'জুন'
@ehzawad
ehzawad / comment.html
Last active September 29, 2023 17:09
Make comment Section in React
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<title>react</title>
<script src="https://unpkg.com/react@latest/dist/react.min.js" async></script>
<script src="https://unpkg.com/react-dom@latest/dist/react-dom.min.js" async></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/babel-standalone/6.21.1/babel.min.js"></script>
</head>
<body>
absl-py==0.13.0
aio-pika==6.8.2
aiofiles==23.1.0
aiohttp==3.7.4
aiormq==3.3.1
APScheduler==3.7.0
astunparse==1.6.3
async-generator==1.10
async-timeout==3.0.1
attrs==21.2.0
@ehzawad
ehzawad / consciousness.md
Created September 23, 2023 16:09
Human Consciousness

I think human consciousness is a tragic misstep in evolution. We became too self-aware. Nature created an aspect of nature separate from itself. We are creatures that should not exist by natural law. We are things that labor under the ilusion of having a self, this accretion of sensory experience and feeling, programmed with total assurance what we are each somebodywhen, in fact, everbody's nobody. I think the honorable thing for our species to do is deny our programming.

@ehzawad
ehzawad / python.txt
Last active September 21, 2023 11:23
python md
You can use the GitHub API to search for repositories, code, commits, issues, users, topics etc. Here is an example of how to search for repositories using Python's `requests` library.
```python
import requests
import json
def search_github(keyword):
url = 'https://api.github.com/search/repositories'
params = {'q': keyword}
response = requests.get(url, params=params)
@ehzawad
ehzawad / install-openssl-from-src-mac
Created September 13, 2023 22:42 — forked from byronmansfield/install-openssl-from-src-mac
Install OpenSSL from source Mac OS X
# Install OpenSSL from source on Mac OS X
# prepare workspace
mkdir -p ~/code/build-from-src/ && cd $_
# download source code
curl -LO https://www.openssl.org/source/openssl-1.1.1d.tar.gz
# expand tar
tar -xzvf openssl-1.1.1d.tar.gz
@ehzawad
ehzawad / numa.sh
Created September 13, 2023 09:03
numa solution!!
#!/bin/bash
if [[ "$EUID" -ne 0 ]]; then
echo "Please run as root."
exit 1
fi
PCI_ID=$(lspci | grep "VGA compatible controller: NVIDIA Corporation" | cut -d' ' -f1)
#PCI_ID="0000:$PCI_ID"
for item in $PCI_ID
do
item="0000:$item"
absl-py==0.15.0
asttokens==2.4.0
astunparse==1.6.3
backcall==0.2.0
cachetools==5.3.1
certifi==2023.7.22
charset-normalizer==3.2.0
clang==5.0
comm==0.1.4
decorator==5.1.1
absl-py==0.13.0
aio-pika==6.8.2
aiofiles==23.1.0
aiohttp==3.7.4
aiormq==3.3.1
APScheduler==3.7.0
astunparse==1.6.3
async-generator==1.10
async-timeout==3.0.1
attrs==21.2.0
from ytmusicapi import YTMusic
# Initialize YTMusic using your OAuth credentials
ytmusic = YTMusic("oauth.json")
# Search for a song
search_results = ytmusic.search('Blank Space By Taylor Swift')
# Check if search results are empty
if not search_results: